Browse Source

CI: update dispatcher script

android-5
Leonid Plyushch 6 years ago
parent
commit
68c6f1c2f3
No known key found for this signature in database GPG Key ID: 45F2964132545795
  1. 12
      scripts/build/ci/cirrus-ci_dispatcher.sh

12
scripts/build/ci/cirrus-ci_dispatcher.sh

@ -28,14 +28,14 @@ set +e
# Process tag '%ci:no-build' that may be added as line to commit message. # Process tag '%ci:no-build' that may be added as line to commit message.
# Will force CI to exit with status 'passed' without performing build. # Will force CI to exit with status 'passed' without performing build.
if grep -qiP '^\s*%ci:no-build\s*$' <(git log --format="%B" -n 1 "$CIRRUS_CHANGE_IN_REPO"); then if grep -qiP '^\s*%ci:no-build\s*$' <(git log --format="%B" -n 1 "$CIRRUS_CHANGE_IN_REPO"); then
echo "[*] Exiting with status 'passed' (tag '%ci:no-build' applied)." echo "[!] Exiting with status 'passed' (tag '%ci:no-build' applied)."
exit 0 exit 0
fi fi
# Process tag '%ci:reset-backlog' that may be added as line to commit message. # Process tag '%ci:reset-backlog' that may be added as line to commit message.
# Will force CI to build changes only for the current commit. # Will force CI to build changes only for the current commit.
if grep -qiP '^\s*%ci:reset-backlog\s*$' <(git log --format="%B" -n 1 "$CIRRUS_CHANGE_IN_REPO"); then if grep -qiP '^\s*%ci:reset-backlog\s*$' <(git log --format="%B" -n 1 "$CIRRUS_CHANGE_IN_REPO"); then
echo "[*] Building only last pushed commit (tag '%ci:reset-backlog' applied)." echo "[!] Building only last pushed commit (tag '%ci:reset-backlog' applied)."
unset CIRRUS_LAST_GREEN_CHANGE unset CIRRUS_LAST_GREEN_CHANGE
unset CIRRUS_BASE_SHA unset CIRRUS_BASE_SHA
fi fi
@ -87,13 +87,13 @@ set -e
echo "[*] Building packages: $PACKAGE_NAMES" echo "[*] Building packages: $PACKAGE_NAMES"
if [ -n "$CIRRUS_PR" ]; then if [ -n "$CIRRUS_PR" ]; then
echo " Pull request: https://github.com/termux/unstable-packages/pull/${CIRRUS_PR}" echo "[*] Pull request: https://github.com/termux/termux-packages/pull/${CIRRUS_PR}"
else else
if [ -n "$CIRRUS_LAST_GREEN_CHANGE" ]; then if [ -n "$CIRRUS_LAST_GREEN_CHANGE" ]; then
echo " Changes: ${CIRRUS_LAST_GREEN_CHANGE}..${CIRRUS_CHANGE_IN_REPO}" echo "[*] Changes: ${CIRRUS_LAST_GREEN_CHANGE}..${CIRRUS_CHANGE_IN_REPO}"
else else
echo " Changes: ${CIRRUS_CHANGE_IN_REPO}" echo "[*] Changes: ${CIRRUS_CHANGE_IN_REPO}"
fi fi
fi fi
./build-package.sh -a "$TERMUX_ARCH" -I "$pkg" $PACKAGE_NAMES ./build-package.sh -a "$TERMUX_ARCH" -I $PACKAGE_NAMES

Loading…
Cancel
Save