Examples of AnyObjectId


Examples of org.eclipse.jgit.lib.AnyObjectId

          JGitText.get().pullTaskName));

    // we check the updates to see which of the updated branches
    // corresponds
    // to the remote branch name
    AnyObjectId commitToMerge;
    if (isRemote) {
      Ref r = null;
      if (fetchRes != null) {
        r = fetchRes.getAdvertisedRef(remoteBranchName);
        if (r == null)
View Full Code Here

Examples of org.eclipse.jgit.lib.AnyObjectId

        bitmapPreparer.doCommitSelection(numCommits);

    beginPhase(PackingPhase.BUILDING_BITMAPS, pm, selectedCommits.size());

    PackWriterBitmapWalker walker = bitmapPreparer.newBitmapWalker();
    AnyObjectId last = null;
    for (PackWriterBitmapPreparer.BitmapCommit cmit : selectedCommits) {
      if (cmit.isReuseWalker())
        walker.reset();
      else
        walker = bitmapPreparer.newBitmapWalker();

      BitmapBuilder bitmap = walker.findObjects(
          Collections.singleton(cmit), null, false);

      if (last != null && cmit.isReuseWalker() && !bitmap.contains(last))
        throw new IllegalStateException(MessageFormat.format(
            JGitText.get().bitmapMissingObject, cmit.name(),
            last.name()));
      last = cmit;
      writeBitmaps.addBitmap(cmit, bitmap.build(), cmit.getFlags());

      pm.update(1);
    }
View Full Code Here

Examples of org.eclipse.jgit.lib.AnyObjectId

          throw new RefNotFoundException(MessageFormat.format(
              JGitText.get().refNotResolved, name));
      }

      RevWalk revWalk = new RevWalk(repo);
      AnyObjectId headId = headRef.getObjectId();
      RevCommit headCommit = headId == null ? null : revWalk
          .parseCommit(headId);
      RevCommit newCommit = revWalk.parseCommit(branch);
      RevTree headTree = headCommit == null ? null : headCommit.getTree();
      DirCacheCheckout dco;
View Full Code Here

Examples of org.eclipse.jgit.lib.AnyObjectId

    tw.addTree(treeId);
    tw.setFilter(PathFilter.create(path));
    tw.setRecursive(true);
    if (!tw.next())
      return null;
    AnyObjectId blobId = tw.getObjectId(0);

    StringBuilder result = new StringBuilder();
    BufferedReader br = null;
    ObjectReader or = r.newObjectReader();
    try {
View Full Code Here

Examples of org.eclipse.jgit.lib.AnyObjectId

   * @throws IOException If an I/O exception occurs.
   */
  private void addRegularFileToIndex(final String fileName,
      final String content, final Repository repository) throws IOException {
    final ObjectInserter oi = repository.newObjectInserter();
    AnyObjectId objectId =
        oi.insert(Constants.OBJ_BLOB, Constants.encode(content));
    oi.flush();
    addEntryToIndex(fileName, FileMode.REGULAR_FILE, objectId, repository);
  }
View Full Code Here

Examples of org.eclipse.jgit.lib.AnyObjectId

          JGitText.get().pullTaskName));

    // we check the updates to see which of the updated branches
    // corresponds
    // to the remote branch name
    AnyObjectId commitToMerge;
    if (isRemote) {
      Ref r = null;
      if (fetchRes != null) {
        r = fetchRes.getAdvertisedRef(remoteBranchName);
        if (r == null)
View Full Code Here

Examples of org.eclipse.jgit.lib.AnyObjectId

          JGitText.get().pullTaskName));

    // we check the updates to see which of the updated branches
    // corresponds
    // to the remote branch name
    AnyObjectId commitToMerge;
    if (isRemote) {
      Ref r = null;
      if (fetchRes != null) {
        r = fetchRes.getAdvertisedRef(remoteBranchName);
        if (r == null)
View Full Code Here

Examples of org.eclipse.jgit.lib.AnyObjectId

      if (branch == null)
        throw new RefNotFoundException(MessageFormat.format(JGitText
            .get().refNotResolved, name));

      RevWalk revWalk = new RevWalk(repo);
      AnyObjectId headId = headRef.getObjectId();
      RevCommit headCommit = headId == null ? null : revWalk
          .parseCommit(headId);
      RevCommit newCommit = revWalk.parseCommit(branch);
      RevTree headTree = headCommit == null ? null : headCommit.getTree();
      DirCacheCheckout dco;
View Full Code Here

Examples of org.eclipse.jgit.lib.AnyObjectId

      if (repoHasBeenRemoved(db)) {
        clearHistoryPage();
        return;
      }

      AnyObjectId headId = resolveHead(db, true);
      if (headId == null) {
        graph.getTableView().setInput(new SWTCommit[0]);
        currentHeadId = null;
        return;
      }
View Full Code Here

Examples of org.eclipse.jgit.lib.AnyObjectId

  protected boolean getFollowRenames() {
    return store.getBoolean(UIPreferences.RESOURCEHISTORY_FOLLOW_RENAMES);
  }

  private AnyObjectId resolveHead(Repository db, boolean acceptNull) {
    AnyObjectId headId;
    try {
      headId = db.resolve(Constants.HEAD);
    } catch (IOException e) {
      throw new IllegalStateException(NLS.bind(
          UIText.GitHistoryPage_errorParsingHead, Activator
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.