JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 247397
  • Score
    100M100P100Q216441F
  • License MIT

Get the git remote origin URL from your local git repository. Remember! A remote origin must exist first!

Package Exports

  • remote-origin-url

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (remote-origin-url) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

remote-origin-url NPM version NPM monthly downloads NPM total downloads Linux Build Status

Get the git remote origin URL from your local git repository. Remember! A remote origin must exist first!

Install

Install with npm:

$ npm install --save remote-origin-url

Install with bower

$ bower install remote-origin-url --save

Usage

Using the defaults:

var remoteOriginUrl = require('remote-origin-url');
remoteOriginUrl(function(err, url) {
  if (err) return console.log(err);
  console.log(url);
  // url => "https://github.com/jonschlinkert/remote-origin-url.git"
});

Specify the cwd to use:

remoteOriginUrl(process.cwd(), function(err, url) {
  if (err) return console.log(err);
  console.log(url);
  // url => "https://github.com/jonschlinkert/remote-origin-url.git"
});

sync

console.log(remoteOriginUrl.sync());
//=> "https://github.com/jonschlinkert/remote-origin-url.git"

Specify the cwd to use:

console.log(remoteOriginUrl.sync(process.cwd()));
//=> "https://github.com/jonschlinkert/remote-origin-url.git"

Release history

v1.0.0

  • no significant changes, just minor code formatting. it's time for a 1.0 release!

v0.5.3

bug fixes

About

Contributing

Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.

Contributors

Commits Contributor
27 jonschlinkert
3 doowb

Building docs

(This project's readme.md is generated by verb, please don't edit the readme directly. Any changes to the readme must be made in the .verb.md readme template.)

To generate the readme, run the following command:

$ npm install -g verbose/verb#dev verb-generate-readme && verb

Running tests

Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:

$ npm install && npm test

Author

Jon Schlinkert

License

Copyright © 2017, Jon Schlinkert. Released under the MIT License.


This file was generated by verb-generate-readme, v0.6.0, on July 11, 2017.