Package org.tmatesoft.hg.core

Examples of org.tmatesoft.hg.core.HgAnnotateCommand.file()


    int rev = cmdLineOpts.getSingleInt(TIP, "-r", "--rev");
    HgAnnotateCommand cmd = repo.createAnnotateCommand();
    AnnotateDumpInspector insp = new AnnotateDumpInspector(cmdLineOpts.getBoolean(false, "-l", "--line-number"));
    cmd.changeset(rev);
    for (String fname : cmdLineOpts.getList("")) {
      cmd.file(Path.create(fname));
      cmd.execute(insp);
    }
  }

  private static class AnnotateDumpInspector implements HgAnnotateCommand.Inspector {
View Full Code Here


    final int changeset = TIP;
    AnnotateInspector ai = new AnnotateInspector();

    cmd.changeset(changeset);
    // follow
    cmd.file(fname);
    cmd.execute(ai);
    AnnotateRunner ar = new AnnotateRunner(fname, repo.getWorkingDir());
    ar.run(changeset, true);
    doAnnotateLineCheck(changeset, ar, ai);
   
View Full Code Here

    AnnotateRunner ar = new AnnotateRunner(fname, repo.getWorkingDir());
    ar.run(changeset, true);
    doAnnotateLineCheck(changeset, ar, ai);
   
    // no follow
    cmd.file(fname, false);
    ai = new AnnotateInspector();
    cmd.execute(ai);
    ar.run(changeset, false);
    doAnnotateLineCheck(changeset, ar, ai);
  }
View Full Code Here

    final String file5AnnotateResult = "0:1:1\n1:2:2x\n4:3:3y\n2:4:z\n5:5:1\n5:6:2x\n5:7:3y\n";
    HgAnnotateCommand cmd = new HgAnnotateCommand(repo);
    cmd.changeset(5);
    AnnotateInspector insp = new AnnotateInspector();
    // file1
    cmd.file(df1, false).execute(insp);
    doAnnotateLineCheck(5, splitLines(file1AnnotateResult), insp);
    // file4
    cmd.file(df4, false).execute(insp = new AnnotateInspector());
    doAnnotateLineCheck(5, splitLines(file4AnnotateResult), insp);
    // file5
View Full Code Here

    AnnotateInspector insp = new AnnotateInspector();
    // file1
    cmd.file(df1, false).execute(insp);
    doAnnotateLineCheck(5, splitLines(file1AnnotateResult), insp);
    // file4
    cmd.file(df4, false).execute(insp = new AnnotateInspector());
    doAnnotateLineCheck(5, splitLines(file4AnnotateResult), insp);
    // file5
    cmd.file(df5, false).execute(insp = new AnnotateInspector());
    doAnnotateLineCheck(5, splitLines(file5AnnotateResult), insp);
}
View Full Code Here

    doAnnotateLineCheck(5, splitLines(file1AnnotateResult), insp);
    // file4
    cmd.file(df4, false).execute(insp = new AnnotateInspector());
    doAnnotateLineCheck(5, splitLines(file4AnnotateResult), insp);
    // file5
    cmd.file(df5, false).execute(insp = new AnnotateInspector());
    doAnnotateLineCheck(5, splitLines(file5AnnotateResult), insp);
}

  // TODO HgWorkingCopyStatusCollector (and HgStatusCollector), with their ancestors (rev 59/69) have examples
  // of *incorrect* assignment of common lines (like "}") - our impl doesn't process common lines in any special way
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.