Home

Awesome

stringify-github-short-url npmjs.com The MIT License

Generate Github / npm shorthand from list of arguments or object.

code climate standard code style travis build status coverage status dependency status

Install

npm i stringify-github-short-url --save

Usage

For more use-cases see the tests

const stringifyGithubShortUrl = require('stringify-github-short-url')

stringifyGithubShortUrl

Generate github / npm shorthand from list of arguments or object.

Example

const gh = require('stringify-github-short-url')

gh('jonschlinkert', 'micromatch')          // => 'jonschlinkert/micromatch'
gh('jonschlinkert', 'micromatch', 'dev')   // => 'jonschlinkert/micromatch#dev'
gh('gulpjs', 'gulp', 'v3.8.1', true)       // => 'gulpjs/gulp@v3.8.1'
gh({
  owner: 'tunnckoCore',
  name: 'parse-function'
}) // => 'tunnckoCore/parse-function'
gh({
  user: 'assemble',
  repo: 'assemble-core'
}) // => 'assemble/assemble-core'

Related

Contributing

Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
But before doing anything, please read the CONTRIBUTING.md guidelines.

Charlike Make Reagent new message to charlike freenode #charlike

tunnckocore.tk keybase tunnckocore tunnckoCore npm tunnckoCore twitter tunnckoCore github