# honey-git-flow

> A new git flow with hooks for waffle.io. And now you have a Waffle with honey.

Latest version **0.1.0** (published 2018-02-01) · MIT license · 0 weekly downloads

## Install

```sh
npm install honey-git-flow
pnpm add honey-git-flow
yarn add honey-git-flow
bun add honey-git-flow
```

Provides the command `honey-git-flow`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.0 |
| Published | 2018-02-01 |
| First published | 2017-09-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=5.12.0 |
| Dependencies | 1 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Ricardo Junior |
| Maintainers | ricardojunior |

## Links

- npm: https://www.npmjs.com/package/honey-git-flow
- Repository: https://github.com/RicardoJunior/honey-git-flow
- Homepage: https://github.com/RicardoJunior/honey-git-flow#readme
- Issues: https://github.com/RicardoJunior/honey-git-flow/issues
- npm.io page: https://npm.io/package/honey-git-flow

## Dependencies (1)

- [husky](https://npm.io/package/husky.md) ^0.11.6

## Recent versions

- 0.1.0 (latest) — 2018-02-01
- 0.0.5 — 2017-09-26
- 0.0.4 — 2017-09-21
- 0.0.3 — 2017-09-21
- 0.0.2 — 2017-09-21
- 0.0.1 — 2017-09-20

## README

# honey-git-flow
A new git flow with hooks for waffle.io. And now you have a Waffle with honey.

## Configure
### Init
You need create in your root folder a gitValidations.json

```
{
    "branchMasters": [
        "master",
        "develop"
    ],
    "branchNames": [
        "feature/#ID_ISSUE/shortest_description",
        "fix/#ID_ISSUE/shortest_description"
    ],
    "commit": {
        "pattern": "<type>(<scope>): <subject>",
        "rules": [
            {
                "type": "regex",
                "rule": "feature|fix|refactor|test|chore",
                "message": "Missing commit (feature, fix, refactor, test or chore)."
            },
            {
                "rule": ":",
                "message": "Missing colon (:)"
            }
        ]
    }
}
```
BranchMasters: It's a property reference for name of your branchs without pattern.
BranchNames: It's a property reference for name of your branchs with pattern.
Commit: It's a template of your commit pattern.

***(remembering that it is necessary everywhere the ids of the issue)***

### Pre-commmit
Add in scripts of your package.json
```
"commitmsg": "node node_modules/honey-git-flow/gitValidations.js commit"
````

### Rebase Blocker (Its a extra)
```
"prerebase": "node node_modules/honey-git-flow/gitValidations.js rebase"
````

*** We have a issue #3 to create a CLI to trigger this in another way ***

## Usage

### Example of commit message
```
git commit -m "feature(new-table) | we develop a new table"
```

**Ps.:** This example apply [Karma Pattern](karma-runner.github.io/2.0/dev/git-commit-msg.html).

### Example of branch name
```
feature/#000/test-feature
fix/#000/test-feature
test/#000/test-feature
```

### Example of PR name
```
closes #000 | test message
```

Ps.: We can use [Github's helper](https://help.github.com/articles/closing-issues-using-keywords/) as prefix in yours PR's 

### Common problems
If your ghooks not triggered, you need to delete **.git/hooks**.
And re-install the ghooks of husky using *$ node node_modules/husky/bin/install.js*

---
_Source: https://npm.io/package/honey-git-flow · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
