File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -39,6 +39,16 @@ const createInitial = (version: string) => {
3939`
4040}
4141
42+ const createChangelog = ( version : string , changelog : string ) => {
43+ if ( changelog ) {
44+ return changelog
45+ }
46+ return `## v${ version } (${ getCurrentDate ( ) } )
47+
48+ No updates!
49+ `
50+ }
51+
4252console . log ( 'Start generating changelog...' )
4353const result = shell . exec ( 'pnpm exec lerna-changelog --next-version-from-metadata' , { silent : true } )
4454
@@ -59,7 +69,7 @@ const BANNER = `
5969### ###
6070#######################`
6171
62- const orgNewChangelog = isNoGitTags ? createInitial ( pkg . version ) : result . stdout
72+ const orgNewChangelog = isNoGitTags ? createInitial ( pkg . version ) : createChangelog ( pkg . version , result . stdout . trim ( ) )
6373
6474const isPreRelease = Boolean ( process . env . VSCODE_WDIO_PRE_RELEASE_PATCH_NUMBER || '' )
6575
You can’t perform that action at this time.
0 commit comments