Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/herrmannplatz/gitlab-url-parse
Parse Gitlab urls
https://github.com/herrmannplatz/gitlab-url-parse
gitlab
Last synced: 24 days ago
JSON representation
Parse Gitlab urls
- Host: GitHub
- URL: https://github.com/herrmannplatz/gitlab-url-parse
- Owner: herrmannplatz
- License: mit
- Created: 2018-10-10T20:24:42.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2018-11-05T19:22:59.000Z (about 6 years ago)
- Last Synced: 2024-12-11T21:12:21.809Z (about 2 months ago)
- Topics: gitlab
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/gitlab-url-parse
- Size: 2.93 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# gitlab-url-parse
[![npm version](https://badge.fury.io/js/gitlab-url-parse.svg)](https://badge.fury.io/js/gitlab-url-parse) [![Build Status](https://travis-ci.org/herrmannplatz/gitlab-url-parse.svg?branch=master)](https://travis-ci.org/herrmannplatz/gitlab-url-parse)
> Parse Gitlab urls
## Install
```
$ npm install gitlab-url-parse
```## Usage
```js
const parse = require('gitlab-url-parse')console.log(parse('https://gitlab.com/herrmannplatz'))
// { user: 'herrmannplatz' }console.log(parse('https://gitlab.com/herrmannplatz/gitlab-url-parse'))
// { user: 'herrmannplatz', project: 'gitlab-url-parse' }console.log(parse('https://gitlab.com/herrmannplatz/gitlab-url-parse/merge_requests/1'))
// { user: 'herrmannplatz', project: 'gitlab-url-parse', mr: 1 }
```