fix(ci): honour FORCE_REBUILD from both manual trigger forms #11
1 changed files with 12 additions and 4 deletions
|
|
@ -181,10 +181,18 @@ steps:
|
||||||
# Escape hatch for when the builder image itself changes in a way that
|
# Escape hatch for when the builder image itself changes in a way that
|
||||||
# alters the resulting R binary (a newly enabled graphics device, a
|
# alters the resulting R binary (a newly enabled graphics device, a
|
||||||
# different BLAS). The artifact filename carries only the R version, so
|
# different BLAS). The artifact filename carries only the R version, so
|
||||||
# dedup would otherwise keep the stale binaries forever. Set FORCE_REBUILD
|
# dedup would otherwise keep the stale binaries forever. Uploads
|
||||||
# to a non-empty value as a pipeline variable on a manual run, or hardcode
|
# overwrite in place.
|
||||||
# it here temporarily; uploads overwrite in place.
|
#
|
||||||
if [ -n "$FORCE_REBUILD" ]; then
|
# The two ways to trigger a manual run pass the flag differently:
|
||||||
|
# crow pipeline create --branch main --var FORCE_REBUILD=1
|
||||||
|
# -> a crow substitution variable, read below as ${FORCE_REBUILD},
|
||||||
|
# which crow blanks out when it was not supplied
|
||||||
|
# crow pipeline start -p FORCE_REBUILD=1
|
||||||
|
# -> injected into the step environment, read as bare $FORCE_REBUILD
|
||||||
|
# Accept either, so the flag cannot be silently ignored.
|
||||||
|
FORCE_REBUILD_VAR="${FORCE_REBUILD}"
|
||||||
|
if [ -n "$FORCE_REBUILD_VAR" ] || [ -n "$FORCE_REBUILD" ]; then
|
||||||
echo "FORCE_REBUILD is set, ignoring artifacts already in the bucket"
|
echo "FORCE_REBUILD is set, ignoring artifacts already in the bucket"
|
||||||
else
|
else
|
||||||
for VERSION in $(cat r-versions-to-build.txt); do
|
for VERSION in $(cat r-versions-to-build.txt); do
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue