Examples of NoHeadException


Examples of org.eclipse.jgit.api.errors.NoHeadException

    try {
      RevWalk revWalk = new RevWalk(reader);

      ObjectId headCommit = repo.resolve(Constants.HEAD);
      if (headCommit == null)
        throw new NoHeadException(JGitText.get().stashApplyWithoutHead);

      final ObjectId stashId = getStashId();
      RevCommit stashCommit = revWalk.parseCommit(stashId);
      if (stashCommit.getParentCount() < 2 || stashCommit.getParentCount() > 3)
        throw new JGitInternalException(MessageFormat.format(JGitText.get().stashCommitIncorrectNumberOfParents, stashId.name(),
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.