abiosoft / abiosoft/caddy-git

Support multiple hooks on the same repository

Offen
#65 2 Kommentare 1 Reaktion 0 zugewiesene Personen Auf GitHub ansehen
enhancement
Vorherrschende Sprache
Go
Sterne
206
Forks
42
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

I'm guessing this is a fairly unique request, but I need the ability to support multiple hooks on the same repo -- the difference is the branch.

You can see the full [Caddyfile here](https://github.com/grindjs/site/blob/master/Caddyfile), but here’s the relevant bits:

```
git github.com/grindjs/docs {
hook /hooks/deploy-docs {$DOCS_SECRET}
hook_type github
branch master
key /apps/.ssh/id_rsa
path ../resources/docs/master
interval -1
}

git github.com/grindjs/docs {
hook /hooks/deploy-docs {$DOCS_SECRET}
hook_type github
branch 0.7
key /apps/.ssh/id_rsa
path ../resources/docs/0.7
interval -1
}

git github.com/grindjs/docs {
hook /hooks/deploy-docs {$DOCS_SECRET}
hook_type github
branch 0.6
key /apps/.ssh/id_rsa
path ../resources/docs/0.6
interval -1
}
```

Basically I have docs for different versions of the framework in branches that can be updated, however when I push to a branch other than master, I get the following:

```
2017/07/19 02:00:45 github webhook ignored. Error: found different branch 0.7
2017/07/19 02:02:13 github webhook ignored. Error: found different branch 0.6
```

I'm guessing the plugin is hitting the first match and then abandoning?

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.