Skip to content

Commit 7d2885d

Browse files
committed
Docs: add installation and usage
1 parent eece8f6 commit 7d2885d

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

README.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,33 @@
22

33
> Check if a git remote repository exists
44
5+
## Installation
6+
7+
```sh
8+
$ npm i is-git-remote --save
9+
```
10+
11+
or
12+
13+
```sh
14+
$ yarn add is-git-remote
15+
```
16+
17+
## Usage
18+
19+
```js
20+
const isGitRemote = require('is-git-remote'); // import isGitRemote from 'is-git-remote'
21+
22+
countGitTags('www.github.com/username/repo-that-exists'); // => true
23+
24+
countGitTags('https://www.github.com/username/repo-that-exists'); // => true
25+
26+
countGitTags('username/repo-that-exists', 'bitbucket.com'); // => true
27+
28+
// automatically checks github if no host is provided
29+
countGitTags('username/repo-that-not-exists'); // => false
30+
```
31+
532
## LICENSE
633

734
MIT © Lukas Aichbauer

0 commit comments

Comments
 (0)