[go: up one dir, main page]

git-remote-origin-url
TypeScript icon, indicating that this package has built-in type declarations

4.0.0 • Public • Published

git-remote-origin-url

Get the remote origin URL of a Git repository

Install

$ npm install git-remote-origin-url

Usage

import gitRemoteOriginUrl from 'git-remote-origin-url';

console.log(await gitRemoteOriginUrl());
//=> 'git@github.com:sindresorhus/git-remote-origin-url.git'

gitRemoteOriginUrl(options?)

options

Type: object

cwd

Type: string
Default: process.cwd()

The current working directory.

remoteName

Type: string
Default: 'origin'

The Git remote name.


Get professional support for this package with a Tidelift subscription
Tidelift helps make open source sustainable for maintainers while giving companies
assurances about security, maintenance, and licensing for their dependencies.

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
4.0.031,484latest

Version History

VersionDownloads (Last 7 Days)Published
4.0.031,484
3.1.037,463
3.0.0330
2.0.05,892,857
1.1.2322
1.1.12
1.1.01
1.0.04
0.1.113

Package Sidebar

Install

npm i git-remote-origin-url

Weekly Downloads

1,915,278

Version

4.0.0

License

MIT

Unpacked Size

3.88 kB

Total Files

5

Last publish

Collaborators

  • sindresorhus