mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-28 12:33:35 +01:00
Merge branch 'master' of https://github.com/matthewferderber/vscode into matthewferderber-master
This commit is contained in:
@@ -996,10 +996,18 @@ export class CommandCenter {
|
||||
return message;
|
||||
}
|
||||
|
||||
const getPreviousCommitMessage = async () => {
|
||||
//Only return the previous commit message if it's an amend commit and the repo already has a commit
|
||||
if (opts && opts.amend && repository.HEAD && repository.HEAD.commit) {
|
||||
return (await repository.getCommit('HEAD')).message;
|
||||
}
|
||||
};
|
||||
|
||||
return await window.showInputBox({
|
||||
value: opts && opts.defaultMsg,
|
||||
placeHolder: localize('commit message', "Commit message"),
|
||||
prompt: localize('provide commit message', "Please provide a commit message"),
|
||||
value: await getPreviousCommitMessage(),
|
||||
ignoreFocusOut: true
|
||||
});
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user