Skip to content

Commit

Permalink
fix: add whitespace after cveId
Browse files Browse the repository at this point in the history
  • Loading branch information
RafaelGSS committed Jan 16, 2025
1 parent 000d25e commit 3007f5f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
2 changes: 1 addition & 1 deletion commit-to-output.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ function toStringPlaintext (data) {
let s = ''

if (data.cveId) {
s += `(${data.cveId})`
s += `(${data.cveId}) `
}

s += (data.semver || []).length ? `(${data.semver.join(', ').toUpperCase()}) ` : ''
Expand Down
10 changes: 10 additions & 0 deletions test.js
Original file line number Diff line number Diff line change
Expand Up @@ -169,3 +169,13 @@ test('test conventionalcommit style', (t) => {
`)
t.end()
})

test('test plaintext, CVE-ID', (t) => {
const out = exec('--start-ref=43d428b3d2 --end-ref=43d428b3d2 --group --filter-release --plaintext')
t.equal(
out,
`feat:
* (CVE-2024-22020) add cveId support to commmit output (RafaelGSS) /~https://github.com/nodejs/node/pull/55819
`)
t.end()
})

0 comments on commit 3007f5f

Please sign in to comment.