mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-23 01:58:53 +01:00
fixes #84201
This commit is contained in:
@@ -1813,6 +1813,12 @@ export class Repository {
|
||||
}
|
||||
|
||||
cleanupCommitEditMessage(message: string): string {
|
||||
// If the message is a single line starting with whitespace followed by `#`, just allow it.
|
||||
if (/^\s*#[^\n]*$/.test(message)) {
|
||||
return message;
|
||||
}
|
||||
|
||||
// Else, remove all lines starting with whitespace followed by `#`.
|
||||
//TODO: Support core.commentChar
|
||||
return message.replace(/^\s*#.*$\n?/gm, '').trim();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user