Skip to content

Commit 8d4600d

Browse files
hanslalexeagle
authored andcommitted
docs: sort changelog by feature first, then fixes
1 parent 5c99662 commit 8d4600d

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

scripts/templates/changelog.ejs

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,13 @@
5656
});
5757
5858
for (const scope of scopes) {
59-
const scopeCommits = commits
60-
.filter(x => x.scope === scope)
61-
.filter(x => ['fix', 'feat'].includes(x.type));
59+
// Do feature first, then fixes.
60+
const allScopeCommits = commits.filter(x => x.scope === scope);
61+
62+
const scopeCommits = [
63+
...allScopeCommits.filter(x => x.type === 'feat'),
64+
...allScopeCommits.filter(x => x.type === 'fix'),
65+
];
6266
6367
if (scopeCommits.length == 0) {
6468
continue;

0 commit comments

Comments
 (0)