mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[git] cherry-pick: use single \n between description and "cherry-picked from...", since Git itself does so.
This commit is contained in:
@@ -226,18 +226,7 @@ public class GitCherryPicker {
|
||||
|
||||
@NotNull
|
||||
private static String createCommitMessage(@NotNull GitCommit commit) {
|
||||
// make sure there is an empty line after description
|
||||
String spaces;
|
||||
if (commit.getDescription().endsWith("\n\n")) {
|
||||
spaces = "";
|
||||
}
|
||||
else if (commit.getDescription().endsWith("\n")) {
|
||||
spaces = "\n";
|
||||
}
|
||||
else {
|
||||
spaces = "\n\n";
|
||||
}
|
||||
return commit.getDescription() + spaces + "(cherry-picked from " + commit.getShortHash().getString() + ")";
|
||||
return commit.getDescription() + "\n(cherry-picked from " + commit.getShortHash().getString() + ")";
|
||||
}
|
||||
|
||||
private boolean showCommitDialogAndWaitForCommit(@NotNull final GitRepository repository, @NotNull final GitCommitWrapper commit,
|
||||
|
||||
Reference in New Issue
Block a user