git_url_parse 0.1.0 git_url_parse: ^0.1.0 copied to clipboard
A high level git url parser for common git providers.
git-url-parse #
A high level git url parser for common git providers.
Usage #
import 'package:git_url_parse/git-url-parse.dart' show gitUrlParse;
void main(){
Map<String,dynamic> gitUrlInfo = gitUrlParse('https+git@github.com:gpmer/gpm.js.git');
print(urlInfo);
}
# print out
{
"href": "https+git@github.com:gpmer/gpm.js.git",
"protocols": [
"https",
"git"
],
"protocol": "https",
"port": 443,
"host": "github.com",
"user": "gpmer",
"password": "",
"origin": "https+git@github.com",
"path": "/gpm.js.git",
"query": "",
"hash": "",
"source": "github.com",
"name": "gpm.js",
"owner": "gpmer",
"full_name": "gpmer/gpm.js"
}
Test #
./TEST
Contribute #
git clone https://github.com/axetroy/git-url-parse.git && cd ./git-url-parse
pub get
./TEST
LICENSE #
The MIT License