Skip to content

Commit c63140c

Browse files
committed
v2.0.0
1 parent c4dd285 commit c63140c

File tree

11 files changed

+28
-79
lines changed

11 files changed

+28
-79
lines changed

.changelog/01.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
breaking
2-
Fixes
2+
Pass in changelog message via command line parameters or prompt

.changelog/02.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
breaking
2+
.git/COMMIT_EDITMSG

.changelog/03.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
breaking
2+
.git/COMMIT_EDITMSG

.husky/commit-msg

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
exec < /dev/tty
2+
node bin/heeler.js add $1
3+
git add .changelog
4+
git commit --amend --no-edit --no-verify

.husky/pre-commit

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1 @@
1-
exec < /dev/tty
2-
node bin/heeler.js add
31
pnpm exec pretty-quick --staged

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
# heeler
2+
3+
## 2.0.0
4+
5+
- breaking: Remove check command, switch to using changelog dir, use MIT license
6+
17
## 1.0.0
28

39
- (feature): Initial implementatation, including prep command. (#3)

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ pnpm i --save-dev heeler husky
99

1010
pnpm exec husky
1111

12-
echo "pnpm exec heeler add" > .husky/pre-commit
12+
echo -e "pnpm exec heeler add $1\ngit add .changelog" > .husky/commit-msg
1313
```
1414

1515
## Usage

bin/heeler.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { select } from "@inquirer/prompts";
1+
import { select, input } from "@inquirer/prompts";
22
import { addToChangelog, prepareRelease } from "../src/changelog-utils.js";
33

44
if (process.argv.length < 3) {
@@ -31,8 +31,13 @@ switch (command) {
3131
],
3232
});
3333

34+
let message = process.argv[3];
35+
if (!message) {
36+
message = await input({ message: "Changelog message" });
37+
}
38+
3439
if (answer !== "skip") {
35-
addToChangelog(answer);
40+
addToChangelog(answer, message);
3641
}
3742
break;
3843
case "prep":

package.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "heeler",
3-
"version": "1.0.0",
3+
"version": "2.0.0",
44
"type": "module",
55
"description": "Changelog pre-commit",
66
"bin": {
@@ -14,8 +14,7 @@
1414
"license": "MIT",
1515
"packageManager": "pnpm@10.13.1",
1616
"dependencies": {
17-
"@inquirer/prompts": "^7.8.0",
18-
"simple-git": "^3.28.0"
17+
"@inquirer/prompts": "^7.8.0"
1918
},
2019
"devDependencies": {
2120
"husky": "^9.1.7",

pnpm-lock.yaml

Lines changed: 0 additions & 61 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)