exit-on-dirty-git

1.0.1 • Public • Published

Exit on dirty git

This module is based on dity-git and just exposes binary that will exit with status code 1 in case there're some uncommitted changes in current working directory.

Can be useful as part of prepublish hook, possibly.

Installation

If you're going to use it from npm-scripts you don't need to install it globally and could just run

npm i exit-on-dirty-git

Usage

Just call it whenever you need it. Sample usage:

  "scripts": {
    "prepublish": "npm run build && exit-on-dirty-git",
  },

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.1
    4
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.1
    4
  • 1.0.0
    0

Package Sidebar

Install

npm i exit-on-dirty-git

Weekly Downloads

4

Version

1.0.1

License

MIT

Last publish

Collaborators

  • sudodoki