altered hook to pull yaml using hash, not branch
This commit is contained in:
parent
07c6c4a4ff
commit
89a88256de
1 changed files with 1 additions and 1 deletions
|
@ -102,7 +102,7 @@ func Hook(w http.ResponseWriter, r *http.Request) error {
|
||||||
|
|
||||||
// get the drone.yml file from GitHub
|
// get the drone.yml file from GitHub
|
||||||
client := github.New(user.GithubToken)
|
client := github.New(user.GithubToken)
|
||||||
content, err := client.Contents.FindRef(repo.Owner, repo.Slug, ".drone.yml", commit.Branch) // TODO should this really be the hash??
|
content, err := client.Contents.FindRef(repo.Owner, repo.Slug, ".drone.yml", commit.Hash)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
msg := "No .drone.yml was found in this repository. You need to add one.\n"
|
msg := "No .drone.yml was found in this repository. You need to add one.\n"
|
||||||
if err := saveFailedBuild(commit, msg); err != nil {
|
if err := saveFailedBuild(commit, msg); err != nil {
|
||||||
|
|
Loading…
Reference in a new issue