fix(mod_commit): Fix changelog template rendering by removing extra new line when no version details are provided.
This commit is contained in:
@ -3,6 +3,6 @@
|
||||
*/
|
||||
export const commitinfo = {
|
||||
name: '@git.zone/cli',
|
||||
version: '1.9.120',
|
||||
version: '1.9.121',
|
||||
description: 'A CLI toolbelt to streamline local development cycles by using various gitzone utilities.'
|
||||
}
|
||||
|
@ -77,7 +77,7 @@ export const run = async (argvArg: any) => {
|
||||
if (nextCommitObject.recommendedNextVersionDetails?.length > 0) {
|
||||
changelog = changelog.replaceAll('{{nextVersionDetails}}', '- ' + nextCommitObject.recommendedNextVersionDetails.join('\n- '));
|
||||
} else {
|
||||
changelog = changelog.replaceAll('\n\n{{nextVersionDetails}}', '');
|
||||
changelog = changelog.replaceAll('\n{{nextVersionDetails}}', '');
|
||||
}
|
||||
|
||||
await plugins.smartfile.memory.toFs(changelog, plugins.path.join(paths.cwd, `changelog.md`));
|
||||
|
Reference in New Issue
Block a user