From 611943487aa4e29ef1729222e7b4b0b2ef036c7b Mon Sep 17 00:00:00 2001 From: Tomi Turtiainen <10324676+tomi@users.noreply.github.com> Date: Fri, 30 Aug 2024 11:07:36 +0300 Subject: [PATCH] ci: Omit benchmark scope commits from changelog (no-changelog) (#10618) --- .github/scripts/update-changelog.mjs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/scripts/update-changelog.mjs b/.github/scripts/update-changelog.mjs index c0cce214a9..2bc571d267 100644 --- a/.github/scripts/update-changelog.mjs +++ b/.github/scripts/update-changelog.mjs @@ -16,7 +16,11 @@ const changelogStream = conventionalChangelog({ releaseCount: 1, tagPrefix: 'n8n@', transform: (commit, callback) => { - callback(null, commit.header.includes('(no-changelog)') ? undefined : commit); + const hasNoChangelogInHeader = commit.header.includes('(no-changelog)'); + const isBenchmarkScope = commit.scope === 'benchmark'; + + // Ignore commits that have 'benchmark' scope or '(no-changelog)' in the header + callback(null, hasNoChangelogInHeader || isBenchmarkScope ? undefined : commit); }, }).on('error', (err) => { console.error(err.stack);