I'm using JGit to programmatically pull remote changes to a local repository. If the pull fails and throws an exception, I want to reset the local repository to the latest commit before the pull attempt.
However, the ResetCommand does not take a commit identifier as an argument, even though the Git reset command accepts a <commit> parameter. Is this a known limitation of the ResetCommand, or am I missing something?
Is there an alternative JGit command that I could use to the same effect?