remove NOPLAN: no longer necessary with new lts workflow

This commit is contained in:
Jens Petersen 2024-01-30 15:24:27 +08:00
parent 20a83fe9c6
commit 9013e10854
2 changed files with 4 additions and 18 deletions

View File

@ -324,16 +324,7 @@ version bound to avoid that version or something else. It's difficult to give
universal advice on how to solve things, since each situation is unique. Let's
develop this advice over time. For now: if you're not sure, ask for guidance.
__`NOPLAN=1`__ If you wish to rerun a build without recalculating a
build plan, you can set the environment variable `NOPLAN=1`. This is
useful for such cases as an intermittent test failure, out of memory
condition, or manually tweaking the plan file. (When using `NOPLAN=1`,
if one needs to revert one package, say due to a build or test regression,
one can edit `snapshot-incomplete.yaml`
(the SHA256 hash of the .cabal file will get updated),
to avoid having to rebuild everything again.)
Note LTS builds without NOPLAN will use the last Hackage data.
Note LTS builds will use the last Hackage data.
You may need to `run-nightly.sh` to get a newer package, but this should be less common for lts.
### Timing

View File

@ -16,6 +16,7 @@ then
WORKDIR=$ROOT/work/$(echo $TARGET | sed 's@^lts-\([0-9]*\)\.[0-9]*@lts-\1@')
if [ -n "$NOPLAN" ]; then
echo '* DO NOT EDIT work/ files: commit to lts-haskell/build-constraints! *'
exit 1
fi
else
TAG=$SHORTNAME
@ -101,17 +102,11 @@ then
fi
# Determine the new build plan unless NOPLAN is set
# Determine the new build plan
#
# * Update the package index (unless LTS)
# * Create a new plan
if [ "${NOPLAN:-}x" = "1x" ]
then
docker run $ARGS_PREBUILD $IMAGE /bin/bash -c "curator snapshot-incomplete --target $TARGET && curator snapshot"
elif [ "${NOPLAN:-}x" = "2x" ]
then
docker run $ARGS_PREBUILD $IMAGE curator snapshot
elif [ $SHORTNAME = "lts" ]
if [ $SHORTNAME = "lts" ]
then
docker run $ARGS_PREBUILD $IMAGE /bin/bash -c "curator constraints --target $TARGET && curator snapshot-incomplete --target $TARGET && curator snapshot"
else