Examples of notesAdd()


Examples of org.eclipse.jgit.api.Git.notesAdd()

   * @return note
   * @throws Exception
   */
  protected Note note(String content, String ref) throws Exception {
    Git git = Git.open(testRepo);
    Note note = git.notesAdd().setMessage(content)
        .setNotesRef(Constants.R_NOTES + ref)
        .setObjectId(CommitUtils.getHead(git.getRepository())).call();
    assertNotNull(note);
    return note;
  }
View Full Code Here

Examples of org.eclipse.jgit.api.Git.notesAdd()

  protected void createNoteInOrigin() throws GitAPIException {
    Git git = new Git(repository1.getRepository());
    git.add().addFilepattern("file.txt").call();
    RevCommit commit = git.commit().setMessage("Initial commit").call();
    git.notesAdd().setNotesRef("refs/notes/review").setObjectId(commit).setMessage("text").call();
  }

}
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.