Skip to content

Commit

Permalink
fix: don't include chore PRs in changelog
Browse files Browse the repository at this point in the history
This change adjusts the release-it config for both this repo, as well as what the create script generates, so that only three categories of changes are included in the changelog entries: feat, fix, and perf.  The idea being that these are the only three types of changes that are generally user-facing.
  • Loading branch information
michaelfaith committed Dec 26, 2024
1 parent 6e81c74 commit 7e859df
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 5 deletions.
14 changes: 13 additions & 1 deletion .release-it.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,19 @@
"plugins": {
"@release-it/conventional-changelog": {
"infile": "CHANGELOG.md",
"preset": "angular"
"preset": "angular",
"types": [
{ "section": "Features", "type": "feat" },
{ "section": "Bug Fixes", "type": "fix" },
{ "section": "Performance Improvements", "type": "perf" },
{ "hidden": true, "type": "build" },
{ "hidden": true, "type": "chore" },
{ "hidden": true, "type": "ci" },
{ "hidden": true, "type": "docs" },
{ "hidden": true, "type": "refactor" },
{ "hidden": true, "type": "style" },
{ "hidden": true, "type": "test" }
]
}
}
}
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@
"lint:spelling": "cspell \"**\" \".github/**/*\"",
"prepare": "husky",
"test": "vitest",
"test:create": "npx tsx script/create-test-e2e.ts",
"test:initialize": "npx tsx script/initialize-test-e2e.ts",
"test:create": "tsx script/create-test-e2e.ts",
"test:initialize": "tsx script/initialize-test-e2e.ts",
"test:migrate": "vitest run -r script/",
"tsc": "tsc"
},
Expand Down
12 changes: 12 additions & 0 deletions src/next/blocks/blockReleaseIt.ts
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,18 @@ export const blockReleaseIt = base.createBlock({
"@release-it/conventional-changelog": {
infile: "CHANGELOG.md",
preset: "angular",
types: [
{ section: "Features", type: "feat" },
{ section: "Bug Fixes", type: "fix" },
{ section: "Performance Improvements", type: "perf" },
{ hidden: true, type: "build" },
{ hidden: true, type: "chore" },
{ hidden: true, type: "ci" },
{ hidden: true, type: "docs" },
{ hidden: true, type: "refactor" },
{ hidden: true, type: "style" },
{ hidden: true, type: "test" },
],
},
},
}),
Expand Down
4 changes: 2 additions & 2 deletions src/steps/writing/creation/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -253,8 +253,8 @@ describe("createStructure", () => {
scripts: {
initialize:
"pnpm build --no-dts && tsx ./bin/index.js --mode initialize",
"test:create": "npx tsx script/create-test-e2e.ts",
"test:initialize": "npx tsx script/initialize-test-e2e.ts",
"test:create": "tsx script/create-test-e2e.ts",
"test:initialize": "tsx script/initialize-test-e2e.ts",
"test:migrate": "vitest run -r script/",
},
},
Expand Down
12 changes: 12 additions & 0 deletions src/steps/writing/creation/rootFiles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,18 @@ export async function createRootFiles(options: Options) {
"@release-it/conventional-changelog": {
infile: "CHANGELOG.md",
preset: "angular",
types: [
{ section: "Features", type: "feat" },
{ section: "Bug Fixes", type: "fix" },
{ section: "Performance Improvements", type: "perf" },
{ hidden: true, type: "build" },
{ hidden: true, type: "chore" },
{ hidden: true, type: "ci" },
{ hidden: true, type: "docs" },
{ hidden: true, type: "refactor" },
{ hidden: true, type: "style" },
{ hidden: true, type: "test" },
],
},
},
}),
Expand Down

0 comments on commit 7e859df

Please sign in to comment.