Skip to content
This repository has been archived by the owner on Mar 27, 2020. It is now read-only.

Husky Git hook to add JIRA ticket ID into the commit message.

License

Notifications You must be signed in to change notification settings

nfq-frontend/jira-prepare-commit-msg

 
 

Repository files navigation

jira-prepare-commit-msg

Husky command to add JIRA ticket ID into the commit message if it is missed.

The JIRA ticket ID is taken from a git branch name.

Installation

Install the package using NPM

npm i -D husky nfq-jira-prepare-commit-msg

Configuration

Inside your package.json add a standard husky npm script for the git hook:

{
  "husky": {
    "hooks": {
      "prepare-commit-msg": "nfq-jira-prepare-commit-msg"
    }
  }
}

Supported pattern

The following patterns are currently supported:

  • /([A-Z]+-\d+)/i

TODO

  • Support user patterns
  • Support configuration (package.json)
  • Lint
  • Tests

License

MIT

About

Husky Git hook to add JIRA ticket ID into the commit message.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 89.7%
  • JavaScript 10.3%