Skip to content

Commit

Permalink
fix: add end of file return to changelog file (#56)
Browse files Browse the repository at this point in the history
* fix: add end of file return to changelog file

* fix: ensure no empty lines between link lines
  • Loading branch information
sjpalf authored Apr 25, 2024
1 parent 36db8c7 commit 6d71e09
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
9 changes: 7 additions & 2 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -28309,7 +28309,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
if (firstVersionLine < lines.length) {
output += '\n' + lines.slice(firstVersionLine).join('\n')
}
output += `\n[${latestTag.name}]: ${githubServerUrl}/${owner}/${repo}/compare/${previousTag.name}...${latestTag.name}`

// add newline character at end of output if it doesn't already exists
if (!output.endsWith('\n')) {
output += '\n'
}
output += `[${latestTag.name}]: ${githubServerUrl}/${owner}/${repo}/compare/${previousTag.name}...${latestTag.name}\n`

// WRITE CHANGELOG TO FILE

Expand All @@ -28322,4 +28327,4 @@ main()

module.exports = __webpack_exports__;
/******/ })()
;
;
7 changes: 6 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
if (firstVersionLine < lines.length) {
output += '\n' + lines.slice(firstVersionLine).join('\n')
}
output += `\n[${latestTag.name}]: ${githubServerUrl}/${owner}/${repo}/compare/${previousTag.name}...${latestTag.name}`

// add newline character at end of output if it doesn't already exists
if (!output.endsWith('\n')) {
output += '\n'
}
output += `[${latestTag.name}]: ${githubServerUrl}/${owner}/${repo}/compare/${previousTag.name}...${latestTag.name}\n`

// WRITE CHANGELOG TO FILE

Expand Down

0 comments on commit 6d71e09

Please sign in to comment.