JSPM

git-remote-url

1.0.1
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 113
  • Score
    100M100P100Q75433F
  • License Apache-2.0

Get a remote URL of a git repository

Package Exports

  • git-remote-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 (git-remote-url) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

git-remote-url

Get a remote URL of a git repository

Build Status dependencies devdependencies

API

The function exported by the module accepts two parameters:

  • directory: the directory of the git repository;
  • remote: the name of the remote you're interested in.

It returns a promise that resolves to the URL of the remote.

Example

var gitRemoteUrl = require('git-remote-url');

gitRemoteUrl('.', 'origin').then(function(url) {
  console.log('URL is ' + url);
});