⚙️ Reduce number of branches to build

This commit is contained in:
Christian Mäder 2018-04-10 10:13:53 +02:00
parent 4bd5f0903f
commit 8ffe6529c9
No known key found for this signature in database
GPG Key ID: 92FFD0A711F196BB
1 changed files with 2 additions and 2 deletions

View File

@ -1,5 +1,5 @@
#!/bin/bash
# Builds all published branches
# Builds develop, develop-* and master branches
ORIGINAL_GITHUB_REPO="digitalocean/netbox"
GITHUB_REPO="${GITHUB_REPO-$ORIGINAL_GITHUB_REPO}"
@ -7,7 +7,7 @@ URL_RELEASES="https://api.github.com/repos/${GITHUB_REPO}/branches"
CURL="curl -sS"
BRANCHES=$($CURL "${URL_RELEASES}" | jq -r 'map(.name) | .[] | scan("^[^v].+")')
BRANCHES=$($CURL "${URL_RELEASES}" | jq -r 'map(.name) | .[] | scan("^[^v].+") | match("^(master|develop).*") | .string')
ERROR=0