Lines Matching full:repo
36 func (git *git) Poll(repo, branch string) (*Commit, error) {
41 if err != nil || strings.TrimSpace(string(origin)) != repo {
42 // The repo is here, but it has wrong origin (e.g. repo in config has changed), re-clone.
43 if err := git.clone(repo, branch); err != nil {
52 if err := git.clone(repo, branch); err != nil {
58 if err := git.clone(repo, branch); err != nil {
68 func (git *git) CheckoutBranch(repo, branch string) (*Commit, error) {
76 _, err := runSandboxed(dir, "git", "fetch", repo, branch)
86 func (git *git) CheckoutCommit(repo, commit string) (*Commit, error) {
94 _, err := runSandboxed(dir, "git", "fetch", repo)
109 func (git *git) clone(repo, branch string) error {
113 if _, err := runSandboxed(git.dir, "git", "remote", "add", "origin", repo); err != nil {
124 return fmt.Errorf("failed to remove repo dir: %v", err)
127 return fmt.Errorf("failed to create repo dir: %v", err)