Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update changelog validation example #25742

Merged
merged 1 commit into from
Feb 8, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions scripts/semantic-commits/validate-changelog.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ function _getResolvedMessage (semanticType, prNumber, associatedIssues = []) {
function _printChangeLogExample (semanticType, prNumber, associatedIssues = []) {
const resolveMessage = _getResolvedMessage(semanticType, prNumber, associatedIssues)

return `${userFacingChanges[semanticType].section}\n - <Insert change details>. ${resolveMessage}`
return `${userFacingChanges[semanticType].section}\n\n - <Insert change details>. ${resolveMessage}`
}

/**
Expand Down Expand Up @@ -132,7 +132,7 @@ async function validateChangelog ({ changedFiles, nextVersion, pendingRelease, c
errors.push(`A changelog entry was not found in cli/CHANGELOG.md.`)

if (commits.length === 1) {
errors.push(`Please add a changelog entry that describes the changes. Include this entry under the section:/\n\n${_printChangeLogExample(commits[0].semanticType, commits[0].prNumber, commits[0].associatedIssues)}`)
errors.push(`Please add a changelog entry that describes the changes. Include this entry under the section:\n\n${_printChangeLogExample(commits[0].semanticType, commits[0].prNumber, commits[0].associatedIssues)}`)

return _handleErrors(errors)
}
Expand Down