docs: sort changelog by feature first, then fixes

This commit is contained in:
Hans Larsen 2018-09-28 17:39:05 -04:00 committed by Alex Eagle
parent 4b7bff0512
commit 52b22bf2e4

View File

@ -56,9 +56,13 @@
});
for (const scope of scopes) {
const scopeCommits = commits
.filter(x => x.scope === scope)
.filter(x => ['fix', 'feat'].includes(x.type));
// Do feature first, then fixes.
const allScopeCommits = commits.filter(x => x.scope === scope);
const scopeCommits = [
...allScopeCommits.filter(x => x.type === 'feat'),
...allScopeCommits.filter(x => x.type === 'fix'),
];
if (scopeCommits.length == 0) {
continue;