diff options
author | Matthias Sohn <matthias.sohn@sap.com> | 2019-01-20 01:38:36 +0100 |
---|---|---|
committer | Matthias Sohn <matthias.sohn@sap.com> | 2019-01-20 01:40:05 +0100 |
commit | 518f420fe60bf0001352cdecd30309c02c90fc2f (patch) | |
tree | 4a5e3d26f5c453397b83f820619d3b0b814cee73 /org.eclipse.jgit.pgm/src/org | |
parent | 637f95b93593f88c1901ef3e780c00e2967f8522 (diff) | |
download | jgit-518f420fe60bf0001352cdecd30309c02c90fc2f.tar.gz jgit-518f420fe60bf0001352cdecd30309c02c90fc2f.zip |
pgm: Fix too wide lines in Commit.run()
Change-Id: I695d1771b808217b0fbde29805e53a819d8c3303
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
Diffstat (limited to 'org.eclipse.jgit.pgm/src/org')
-rw-r--r-- | org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Commit.java | 7 | ||||
-rw-r--r-- | org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/internal/CLIText.java | 2 |
2 files changed, 5 insertions, 4 deletions
diff --git a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Commit.java b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Commit.java index d1ab529deb..b0713f782c 100644 --- a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Commit.java +++ b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Commit.java @@ -107,7 +107,7 @@ class Commit extends TextBuiltin { throw die(CLIText.get().pathsRequired); } if (only && all) { - throw die(CLIText.get().onlyOneOfIncludeOnlyAllInteractiveCanBeUsed); + throw die(CLIText.get().onlyOneCommitOptionAllowed); } if (!paths.isEmpty()) { for (String p : paths) { @@ -133,10 +133,11 @@ class Commit extends TextBuiltin { } else { branchName = head.getTarget().getName(); if (branchName.startsWith(Constants.R_HEADS)) { - branchName = branchName.substring(Constants.R_HEADS.length()); + branchName = branchName + .substring(Constants.R_HEADS.length()); } } - outw.println("[" + branchName + " " + commit.name() + "] " //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + outw.println('[' + branchName + ' ' + commit.name() + "] " //$NON-NLS-1$ + commit.getShortMessage()); } catch (IOException e) { throw die(e.getMessage(), e); diff --git a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/internal/CLIText.java b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/internal/CLIText.java index b3ad8bf403..397b6b14ba 100644 --- a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/internal/CLIText.java +++ b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/internal/CLIText.java @@ -278,7 +278,7 @@ public class CLIText extends TranslationBundle { /***/ public String onBranchToBeBorn; /***/ public String onBranch; /***/ public String onlyOneMetaVarExpectedIn; - /***/ public String onlyOneOfIncludeOnlyAllInteractiveCanBeUsed; + /***/ public String onlyOneCommitOptionAllowed; /***/ public String password; /***/ public String pathspecDidNotMatch; /***/ public String pushTo; |