Lines Matching full:branch
285 * @param string identifyer to id the branch/commit/position
288 public function getFile($filename, $branch = 'HEAD') { argument
290 $cmd = 'show '.$branch.':'.$filename;
325 $pos = strpos($status, 'Your branch is ahead of');
479 * Runs a `git branch` call
481 * Accepts a name for the branch
484 * @param string branch name
487 public function create_branch($branch) { argument
488 return $this->run("branch $branch");
492 * Runs a `git branch -[d|D]` call
494 * Accepts a name for the branch
497 * @param string branch name
500 public function delete_branch($branch, $force = false) { argument
501 return $this->run("branch ".(($force) ? '-D' : '-d')." $branch");
505 * Runs a `git branch` call
508 * @param bool keep asterisk mark on active branch
512 $branchArray = explode("\n", $this->run("branch"));
513 foreach($branchArray as $i => &$branch) {
514 $branch = trim($branch);
516 $branch = str_replace("* ", "", $branch);
517 if ($branch == "")
524 * Returns name of active branch
527 * @param bool keep asterisk mark on branch name
543 * Accepts a name for the branch
546 * @param string branch name
549 public function checkout($branch) { argument
550 return $this->run("checkout $branch");
557 * Accepts a name for the branch to be merged
560 * @param string $branch
563 public function merge($branch, $msg = "") argument
565 if ($msg == "") return $this->run("merge $branch --no-ff");
566 return $this->run("merge $branch --no-ff -m ".$msg);
584 * Runs a git fetch on the current branch
633 * Push specific branch to a remote
644 * Pull specific branch from remote
646 * Accepts the name of the remote and local branch
649 * @param string $branch
652 public function pull($remote, $branch) argument
654 return $this->run("pull $remote $branch");