is-git-remote

Check if a git remote repository exists

Usage no npm install needed!

<script type="module">
  import isGitRemote from 'https://cdn.skypack.dev/is-git-remote';
</script>

README

is-git-remote

Check if a git remote repository exists

Build Status Build status codecov

Installation

$ npm i is-git-remote --save

or

$ yarn add is-git-remote

Usage

const isGitRemote = require('is-git-remote'); // import isGitRemote from 'is-git-remote'

isGitRemote('www.github.com/username/repo-that-exists'); // => true

isGitRemote('https://www.github.com/username/repo-that-exists'); // => true

isGitRemote('username/repo-that-exists', 'bitbucket.com'); // => true

// automatically checks github if no host is provided
isGitRemote('username/repo-that-not-exists'); // => false

LICENSE

MIT © Lukas Aichbauer