git: remove dead code

This commit is contained in:
Aleksey Pivovarov
2018-06-07 12:49:53 +03:00
parent df5aff895d
commit 41770253d8
@@ -81,17 +81,6 @@ class GitDeleteTagOperation extends GitBranchOperation {
myNotifier.notify(notification);
}
@Override
protected void rollback() {
GitCompoundResult result = doRollback();
if (result.totalSuccess()) {
myNotifier.notifySuccess("Rollback Successful", "Restored tag " + myTagName);
}
else {
myNotifier.notifyError("Error during rollback of tag deletion", result.getErrorOutputWithReposIndication());
}
}
@NotNull
private GitCompoundResult doRollback() {
GitCompoundResult result = new GitCompoundResult(myProject);
@@ -103,25 +92,6 @@ class GitDeleteTagOperation extends GitBranchOperation {
return result;
}
@NotNull
public String getSuccessMessage() {
return String.format("Deleted tag %s", formatTagName(myTagName));
}
@NotNull
@Override
protected String getRollbackProposal() {
return "However tag deletion has succeeded for the following " + repositories() + ":<br/>" +
successfulRepositoriesJoined() +
"<br/>You may rollback (recreate " + myTagName + " in these roots) not to let tags diverge.";
}
@NotNull
@Override
protected String getOperationName() {
return "tag deletion";
}
@NotNull
private static String formatTagName(@NotNull String name) {
return "<b><code>" + name + "</code></b>";
@@ -145,4 +115,26 @@ class GitDeleteTagOperation extends GitBranchOperation {
myNotifier.notifyError("Couldn't Restore " + formatTagName(myTagName), result.getErrorOutputWithReposIndication());
}
}
@Override
protected void rollback() {
throw new UnsupportedOperationException();
}
@NotNull
@Override
protected String getRollbackProposal() {
throw new UnsupportedOperationException();
}
@NotNull
@Override
protected String getOperationName() {
throw new UnsupportedOperationException();
}
@NotNull
public String getSuccessMessage() {
throw new UnsupportedOperationException();
}
}