Browse Source

Add toString() to CherryPickCommand and ResetCommand

Change-Id: Ie2dd87943350e3b0a2df72a70e5219139d110a8f
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
stable-4.6
Matthias Sohn 8 years ago
parent
commit
f6df5cf26e
  1. 11
      org.eclipse.jgit/src/org/eclipse/jgit/api/CherryPickCommand.java
  2. 8
      org.eclipse.jgit/src/org/eclipse/jgit/api/ResetCommand.java

11
org.eclipse.jgit/src/org/eclipse/jgit/api/CherryPickCommand.java

@ -330,4 +330,15 @@ public class CherryPickCommand extends GitCommand<CherryPickResult> {
String headName = Repository.shortenRefName(targetRefName); String headName = Repository.shortenRefName(targetRefName);
return headName; return headName;
} }
@SuppressWarnings("nls")
@Override
public String toString() {
return "CherryPickCommand [repo=" + repo + ",\ncommits=" + commits
+ ",\nmainlineParentNumber=" + mainlineParentNumber
+ ", noCommit=" + noCommit + ", ourCommitName=" + ourCommitName
+ ", reflogPrefix=" + reflogPrefix + ", strategy=" + strategy
+ "]";
}
} }

8
org.eclipse.jgit/src/org/eclipse/jgit/api/ResetCommand.java

@ -432,4 +432,12 @@ public class ResetCommand extends GitCommand<Ref> {
repo.writeMergeCommitMsg(null); repo.writeMergeCommitMsg(null);
} }
@SuppressWarnings("nls")
@Override
public String toString() {
return "ResetCommand [repo=" + repo + ", ref=" + ref + ", mode=" + mode
+ ", isReflogDisabled=" + isReflogDisabled + ", filepaths="
+ filepaths + "]";
}
} }

Loading…
Cancel
Save