/** * Set the name of the new branch * * @param name * the name of the new branch * @return this instance */ public CreateBranchCommand setName(String name) { checkCallable(); this.name = name; return this; }
/** * Set whether to create the branch forcefully * * @param force * if <code>true</code> and the branch with the given name * already exists, the start-point of an existing branch will be * set to a new start-point; if false, the existing branch will * not be changed * @return this instance */ public CreateBranchCommand setForce(boolean force) { checkCallable(); this.force = force; return this; }
/** * Set the start point * * @param startPoint * corresponds to the start-point option; if <code>null</code>, * the current HEAD will be used * @return this instance */ public CreateBranchCommand setStartPoint(String startPoint) { checkCallable(); this.startPoint = startPoint; this.startCommit = null; return this; }
/** * Set the upstream mode * * @param mode * corresponds to the --track/--no-track/--set-upstream options; * may be <code>null</code> * @return this instance */ public CreateBranchCommand setUpstreamMode(SetupUpstreamMode mode) { checkCallable(); this.upstreamMode = mode; return this; } }
/** * Set the start point * * @param startPoint * corresponds to the start-point option; if <code>null</code>, * the current HEAD will be used * @return this instance */ public CreateBranchCommand setStartPoint(RevCommit startPoint) { checkCallable(); this.startCommit = startPoint; this.startPoint = null; return this; }
/** * @param startPoint * corresponds to the start-point option; if <code>null</code>, * the current HEAD will be used * @return this instance */ public CreateBranchCommand setStartPoint(String startPoint) { checkCallable(); this.startPoint = startPoint; this.startCommit = null; return this; }
/** * @param name * the name of the new branch * @return this instance */ public CreateBranchCommand setName(String name) { checkCallable(); this.name = name; return this; }
/** * @param mode * corresponds to the --track/--no-track/--set-upstream options; * may be <code>null</code> * @return this instance */ public CreateBranchCommand setUpstreamMode(SetupUpstreamMode mode) { checkCallable(); this.upstreamMode = mode; return this; } }
/** * @param startPoint * corresponds to the start-point option; if <code>null</code>, * the current HEAD will be used * @return this instance */ public CreateBranchCommand setStartPoint(RevCommit startPoint) { checkCallable(); this.startCommit = startPoint; this.startPoint = null; return this; }
/** * Set the name of the new branch * * @param name * the name of the new branch * @return this instance */ public CreateBranchCommand setName(String name) { checkCallable(); this.name = name; return this; }
/** * @param force * if <code>true</code> and the branch with the given name * already exists, the start-point of an existing branch will be * set to a new start-point; if false, the existing branch will * not be changed * @return this instance */ public CreateBranchCommand setForce(boolean force) { checkCallable(); this.force = force; return this; }
/** * Set the upstream mode * * @param mode * corresponds to the --track/--no-track/--set-upstream options; * may be <code>null</code> * @return this instance */ public CreateBranchCommand setUpstreamMode(SetupUpstreamMode mode) { checkCallable(); this.upstreamMode = mode; return this; } }
/** * Set the start point * * @param startPoint * corresponds to the start-point option; if <code>null</code>, * the current HEAD will be used * @return this instance */ public CreateBranchCommand setStartPoint(String startPoint) { checkCallable(); this.startPoint = startPoint; this.startCommit = null; return this; }
/** * Set the start point * * @param startPoint * corresponds to the start-point option; if <code>null</code>, * the current HEAD will be used * @return this instance */ public CreateBranchCommand setStartPoint(RevCommit startPoint) { checkCallable(); this.startCommit = startPoint; this.startPoint = null; return this; }
/** * Set whether to create the branch forcefully * * @param force * if <code>true</code> and the branch with the given name * already exists, the start-point of an existing branch will be * set to a new start-point; if false, the existing branch will * not be changed * @return this instance */ public CreateBranchCommand setForce(boolean force) { checkCallable(); this.force = force; return this; }
public Ref call() throws GitAPIException, RefAlreadyExistsException, RefNotFoundException, InvalidRefNameException { checkCallable(); processOptions(); try (RevWalk revWalk = new RevWalk(repo)) {
public Ref call() throws GitAPIException, RefAlreadyExistsException, RefNotFoundException, InvalidRefNameException { checkCallable(); processOptions(); try (RevWalk revWalk = new RevWalk(repo)) {
checkCallable(); processOptions(); try (RevWalk revWalk = new RevWalk(repo)) {