diff --git a/ng-dev/release/snapshot-publish/snapshots.ts b/ng-dev/release/snapshot-publish/snapshots.ts index e71016a30..6c4aef7d8 100644 --- a/ng-dev/release/snapshot-publish/snapshots.ts +++ b/ng-dev/release/snapshot-publish/snapshots.ts @@ -161,9 +161,16 @@ export class SnapshotPublisher { ['diff-index', '--quiet', '-I', '0\\.0\\.0-[a-f0-9]+', 'HEAD', '--'], {cwd: tmpRepoDir}, ).status === 1; - this.git.run(['commit', '--author', this.commitAuthor, '-m', this.snapshotCommitMessage], { - cwd: tmpRepoDir, - }); + this.git.run( + [ + 'commit', + '--author', + this.commitAuthor, + '-m', + `"${this.snapshotCommitMessage.replace(/"/g, '\\"')}"`, + ], + {cwd: tmpRepoDir}, + ); return { url,