Socket
Socket
Sign inDemoInstall

github-url-to-object

Package Overview
Dependencies
Maintainers
1
Versions
44
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github-url-to-object - npm Package Compare versions

Comparing version 0.5.0 to 0.5.1

.travis.yml

8

package.json
{
"name": "github-url-to-object",
"version": "0.5.0",
"description": "Extract username and repo name from various flavors of GitHub URLs",
"version": "0.5.1",
"description": "Extract user, repo, and other interesting properties from GitHub URLs",
"main": "index.js",
"scripts": {
"test": "mocha ./test/*.js"
"test": "mocha"
},

@@ -19,3 +19,3 @@ "repository": {

"author": "zeke",
"license": "WTFPL",
"license": "MIT",
"bugs": {

@@ -22,0 +22,0 @@ "url": "https://github.com/zeke/github-url-to-object/issues"

@@ -1,4 +0,5 @@

# github-url-to-object
# github-url-to-object [![Build Status](https://travis-ci.org/zeke/github-url-to-object.png?branch=master)](https://travis-ci.org/zeke/github-url-to-object)
Extract username and repo name from various flavors of GitHub URLs.
A node module that extracts useful properties like `user` and
`repo` from various flavors of GitHub URLs.

@@ -18,3 +19,3 @@ ## Installation

gh('user/repo')
gh('monkey/business')
gh('https://github.com/monkey/business')

@@ -26,3 +27,3 @@ gh('https://github.com/monkey/business.git')

Here's what you'll get back:
Here's what you'll get:

@@ -32,7 +33,9 @@ ```js

user: 'monkey',
repo: 'business'
repo: 'business',
https_url: 'https://github.com/monkey/business',
tarball_url: 'https://api.github.com/repos/monkey/business/tarball'
}
```
If you provide a non-github URL or a falsy value, you'll get `null` back.
If you provide a non-github URL or a falsy value, you'll get `null`.

@@ -42,2 +45,3 @@ ## Test

```sh
npm install
npm test

@@ -48,2 +52,2 @@ ```

WTFPL
MIT
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc