aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomasz Zarna2012-04-02 05:36:29 (EDT)
committerTomasz Zarna2012-04-02 05:36:29 (EDT)
commit622232b936fee6d2f308947359b4bc09811ce556 (patch)
treec5516b45e4f73a472b8627f692b272896e88a47b
parent6189a68d1d48e38779380cea81efa530405ff762 (diff)
downloadjgit-622232b936fee6d2f308947359b4bc09811ce556.zip
jgit-622232b936fee6d2f308947359b4bc09811ce556.tar.gz
jgit-622232b936fee6d2f308947359b4bc09811ce556.tar.bz2
Externalize parsing exception message for RebaseCommand#Actionrefs/changes/15/5515/1
-rw-r--r--org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties1
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseCommand.java8
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java1
3 files changed, 5 insertions, 5 deletions
diff --git a/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties b/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties
index 0554efa..93392e2 100644
--- a/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties
+++ b/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties
@@ -476,6 +476,7 @@ unexpectedOddResult=odd: {0} + {1} - {2}
unexpectedRefReport={0}: unexpected ref report: {1}
unexpectedReportLine=unexpected report line: {0}
unexpectedReportLine2={0} unexpected report line: {1}
+unknownOrUnsupportedCommand=Unknown or unsupported command "{0}", only "{1}" is allowed.
unknownDIRCVersion=Unknown DIRC version {0}
unknownHost=unknown host
unknownIndexVersionOrCorruptIndex=Unknown index version (or corrupt index): {0}
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseCommand.java
index 7765c5d..aa65726 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseCommand.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseCommand.java
@@ -955,11 +955,9 @@ public class RebaseCommand extends GitCommand<RebaseResult> {
static Action parse(String token) {
if (token.equals("pick") || token.equals("p"))
return PICK;
- throw new JGitInternalException(
- MessageFormat
- .format(
- "Unknown or unsupported command \"{0}\", only \"pick\" is allowed",
- token));
+ throw new JGitInternalException(MessageFormat.format(
+ JGitText.get().unknownOrUnsupportedCommand, token,
+ PICK.toToken()));
}
}
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java
index c9f5d33..bcc9589 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java
@@ -536,6 +536,7 @@ public class JGitText extends TranslationBundle {
/***/ public String unexpectedRefReport;
/***/ public String unexpectedReportLine;
/***/ public String unexpectedReportLine2;
+ /***/ public String unknownOrUnsupportedCommand;
/***/ public String unknownDIRCVersion;
/***/ public String unknownHost;
/***/ public String unknownIndexVersionOrCorruptIndex;