🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

github-from-package

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github-from-package

return the github url from a package.json file

0.0.0
latest
Source
npm
Version published
Weekly downloads
8.9M
-1.57%
Maintainers
1
Weekly downloads
 
Created
Source

github-from-package

return the github url from a package.json file

build status

example

For the ./package.json file:

{
  "name": "beep-boop",
  "version": "1.2.3",
  "repository" : {
    "type" : "git",
    "url": "git@github.com:substack/beep-boop.git"
  }
}
var github = require('github-from-package');
var url = github(require('./package.json'));
console.log(url);
https://github.com/substack/beep-boop

methods

var github = require('github-from-package')

var url = github(pkg)

Return the most likely github url from the package.json contents pkg. If no github url can be determined, return undefined.

install

With npm do:

npm install github-from-package

license

MIT

Keywords

github

FAQs

Package last updated on 29 Dec 2012

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts