mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-28 16:46:16 +02:00
housekeeping: shellcheck for tests/functional/ca/substitute.sh
This commit is contained in:
parent
04876c39e4
commit
259b502773
1 changed files with 7 additions and 6 deletions
|
@ -4,9 +4,10 @@
|
||||||
|
|
||||||
source common.sh
|
source common.sh
|
||||||
|
|
||||||
|
# shellcheck disable=SC1111
|
||||||
needLocalStore "“--no-require-sigs” can’t be used with the daemon"
|
needLocalStore "“--no-require-sigs” can’t be used with the daemon"
|
||||||
|
|
||||||
rm -rf $TEST_ROOT/binary_cache
|
rm -rf "$TEST_ROOT"/binary_cache
|
||||||
|
|
||||||
export REMOTE_STORE_DIR=$TEST_ROOT/binary_cache
|
export REMOTE_STORE_DIR=$TEST_ROOT/binary_cache
|
||||||
export REMOTE_STORE=file://$REMOTE_STORE_DIR
|
export REMOTE_STORE=file://$REMOTE_STORE_DIR
|
||||||
|
@ -17,11 +18,11 @@ buildDrvs () {
|
||||||
|
|
||||||
# Populate the remote cache
|
# Populate the remote cache
|
||||||
clearStore
|
clearStore
|
||||||
nix copy --to $REMOTE_STORE --file ./content-addressed.nix
|
nix copy --to "$REMOTE_STORE" --file ./content-addressed.nix
|
||||||
|
|
||||||
# Restart the build on an empty store, ensuring that we don't build
|
# Restart the build on an empty store, ensuring that we don't build
|
||||||
clearStore
|
clearStore
|
||||||
buildDrvs --substitute --substituters $REMOTE_STORE --no-require-sigs -j0 transitivelyDependentCA
|
buildDrvs --substitute --substituters "$REMOTE_STORE" --no-require-sigs -j0 transitivelyDependentCA
|
||||||
# Check that the thing we’ve just substituted has its realisation stored
|
# Check that the thing we’ve just substituted has its realisation stored
|
||||||
nix realisation info --file ./content-addressed.nix transitivelyDependentCA
|
nix realisation info --file ./content-addressed.nix transitivelyDependentCA
|
||||||
# Check that its dependencies have it too
|
# Check that its dependencies have it too
|
||||||
|
@ -63,9 +64,9 @@ clearStore
|
||||||
# Add the realisations of rootCA to the cachecache
|
# Add the realisations of rootCA to the cachecache
|
||||||
clearCacheCache
|
clearCacheCache
|
||||||
export _NIX_FORCE_HTTP=1
|
export _NIX_FORCE_HTTP=1
|
||||||
buildDrvs --substitute --substituters $REMOTE_STORE --no-require-sigs -j0
|
buildDrvs --substitute --substituters "$REMOTE_STORE" --no-require-sigs -j0
|
||||||
# Try rebuilding, but remove the realisations from the remote cache to force
|
# Try rebuilding, but remove the realisations from the remote cache to force
|
||||||
# using the cachecache
|
# using the cachecache
|
||||||
clearStore
|
clearStore
|
||||||
rm $REMOTE_STORE_DIR/realisations/*
|
rm "$REMOTE_STORE_DIR"/realisations/*
|
||||||
buildDrvs --substitute --substituters $REMOTE_STORE --no-require-sigs -j0
|
buildDrvs --substitute --substituters "$REMOTE_STORE" --no-require-sigs -j0
|
||||||
|
|
Loading…
Reference in a new issue