Skip to content

Commit

Permalink
Panic if ci only gets HEAD for current branch
Browse files Browse the repository at this point in the history
  • Loading branch information
davegaeddert committed Sep 10, 2019
1 parent bb6bdf5 commit 4e3149e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions internal/runner/ci.go
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,10 @@ func getCurrentBranch(ci ci.CIProvider) string {
panic(errors.New("Unable to determine base branch"))
}

if branch == "HEAD" {
panic(errors.New("Unable to determine base branch, only got HEAD"))
}

return branch
}

Expand Down

0 comments on commit 4e3149e

Please sign in to comment.