Skip to content

Commit

Permalink
fix: use --pretty=format:"%B" instead of --pretty=%B
Browse files Browse the repository at this point in the history
The latter adds unnecessary whitespace at the end of the commit msg.
  • Loading branch information
knocte committed Mar 13, 2024
1 parent 06a3ed8 commit 78d1edc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion @commitlint/read/src/read.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export default async function getCommitMessages(
}

if (last) {
const executeGitCommand = await execa('git', ['log', '-1', '--pretty=%B']);
const executeGitCommand = await execa('git', ['log', '-1', '--pretty=format:"%B"']);
return [executeGitCommand.stdout];
}

Expand Down

0 comments on commit 78d1edc

Please sign in to comment.