repo-path-parse

2018-09-15 admin

repo-path-parse是什么

什么是repo-path-parse,parse repository path strings to get repository and organization parts

repo-path-parse使用教程帮助文档

repo-path-parse

build status

parse repository path strings to get repository and organization parts

repo-path-parse(url)

Parse git remote URLs into an object with owner and repo keys.

Parameters

parameter type description
url String any git-clonable URL that points to GitHub

Example

var repoPathParse = require('repo-path-parse');
repoPathParse('git@github.com:tmcw/repo-path-parse.git');
// returns { owner: 'tmcw', repo: 'repo-path-parse' }

Returns Object, an object of {owner:'owner',repo:'repo'}

Installation

Requires nodejs.

$ npm install repo-path-parse

Tests

$ npm test

本站文章除注明转载外,均为本站原创或编译。欢迎任何形式的转载,但请务必注明出处。

转载请注明:文章转载自 JavaScript中文网 [https://www.javascriptcn.com]

本文地址:https://www.javascriptcn.com/read-40318.html

文章标题:repo-path-parse

回到顶部