Browse Source

CI: refactor configuration file

Cache instructions will query system to check if existing cache is available.
While cache will unlikely to be available in build task, it is better to
make it queried before build so if cache folder appear, it will be deleted by
`rm -rf "debs-${TERMUX_ARCH}"`.
emacs-27
Leonid Plyushch 6 years ago
parent
commit
004ff1bd93
No known key found for this signature in database GPG Key ID: 45F2964132545795
  1. 34
      .cirrus.yml

34
.cirrus.yml

@ -31,6 +31,23 @@ build_task:
git reset --hard "$CIRRUS_CHANGE_IN_REPO"
fi
# Setup cache to make built packages available for the next tasks.
share_aarch64_packages_cache:
folder: "./cached-debs-aarch64"
fingerprint_script: echo "${CIRRUS_CHANGE_IN_REPO}-aarch64"
share_arm_packages_cache:
folder: "./cached-debs-arm"
fingerprint_script: echo "${CIRRUS_CHANGE_IN_REPO}-arm"
share_i686_packages_cache:
folder: "./cached-debs-i686"
fingerprint_script: echo "${CIRRUS_CHANGE_IN_REPO}-i686"
share_x86_64_packages_cache:
folder: "./cached-debs-x86_64"
fingerprint_script: echo "${CIRRUS_CHANGE_IN_REPO}-x86_64"
# Determine changes in repository and build modified packages.
build_script: |
for package in $(./scripts/build/ci/determine_git_changes.sh); do
@ -48,23 +65,6 @@ build_task:
cp -a "cached-debs-${TERMUX_ARCH}" ./debs
fi
# Make built packages available for the next tasks.
share_aarch64_packages_cache:
folder: "./cached-debs-aarch64"
fingerprint_script: echo "${CIRRUS_CHANGE_IN_REPO}-aarch64"
share_arm_packages_cache:
folder: "./cached-debs-arm"
fingerprint_script: echo "${CIRRUS_CHANGE_IN_REPO}-arm"
share_i686_packages_cache:
folder: "./cached-debs-i686"
fingerprint_script: echo "${CIRRUS_CHANGE_IN_REPO}-i686"
share_x86_64_packages_cache:
folder: "./cached-debs-x86_64"
fingerprint_script: echo "${CIRRUS_CHANGE_IN_REPO}-x86_64"
# Also make them downloadable from the UI.
store_packages_artifacts:
path: "./debs/*.deb"

Loading…
Cancel
Save