https://github.com/jpeer264/node-is-merge-commit
A tool to check if a specific commit is a merge commit
https://github.com/jpeer264/node-is-merge-commit
git is-git merge nodejs repository
Last synced: 25 days ago
JSON representation
A tool to check if a specific commit is a merge commit
- Host: GitHub
- URL: https://github.com/jpeer264/node-is-merge-commit
- Owner: JPeer264
- License: mit
- Created: 2020-07-02T17:52:32.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2023-01-06T11:16:35.000Z (over 3 years ago)
- Last Synced: 2025-02-16T06:02:54.549Z (over 1 year ago)
- Topics: git, is-git, merge, nodejs, repository
- Language: TypeScript
- Homepage:
- Size: 1.09 MB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 11
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# is-merge-commit
[](https://travis-ci.com/JPeer264/node-is-merge-commit)
[](https://ci.appveyor.com/project/JPeer264/node-is-merge-commit)
[](https://coveralls.io/github/JPeer264/node-is-merge-commit?branch=master)
Get synchronously the current branch name
## Installation
```sh
$ npm i is-merge-commit --save
```
or
```sh
$ yarn add is-merge-commit
```
## Usage
**isMergeCommit(commit[, options])**
Parameters:
- commit ``: The git commit identifier
- options `` (optional)
Options:
- cwd ``: Current working directory for the git execution
Returns:
- Boolean: Wether it is a merge commit or not
```js
const isMergeCommit = require('is-merge-commit');
isMergeCommit('8bc8ea6'); // true | false
isMergeCommit('8bc8ea6', { cwd: 'any/git/repo' }); // true | false
```
## LICENSE
MIT © [Jan Peer Stöcklmair](https://www.jpeer.at)