mirror of
https://github.com/element-hq/synapse.git
synced 2026-03-29 04:29:54 +00:00
complement.sh: ensure old complement checkout files are deleted; remove -N wget flag (#19592)
This commit is contained in:
1
changelog.d/19592.misc
Normal file
1
changelog.d/19592.misc
Normal file
@@ -0,0 +1 @@
|
||||
Ensure old Complement test files are removed when downloading a Complement checkout via `./scripts-dev/complement.sh`.
|
||||
@@ -160,8 +160,18 @@ main() {
|
||||
if [[ -z "$COMPLEMENT_DIR" ]]; then
|
||||
COMPLEMENT_REF=${COMPLEMENT_REF:-main}
|
||||
echo "COMPLEMENT_DIR not set. Fetching Complement checkout from ${COMPLEMENT_REF}..."
|
||||
wget -Nq https://github.com/matrix-org/complement/archive/${COMPLEMENT_REF}.tar.gz
|
||||
|
||||
# Download the Complement checkout at the specified ref.
|
||||
wget -q https://github.com/matrix-org/complement/archive/${COMPLEMENT_REF}.tar.gz
|
||||
|
||||
# Delete the existing complement checkout. Otherwise we'll end up with stale
|
||||
# test files after they're deleted server-side, and `tar` will not delete
|
||||
# old files.
|
||||
rm -rf complement-${COMPLEMENT_REF}
|
||||
|
||||
# Extract the checkout.
|
||||
tar -xzf ${COMPLEMENT_REF}.tar.gz
|
||||
|
||||
COMPLEMENT_DIR=complement-${COMPLEMENT_REF}
|
||||
echo "Checkout available at 'complement-${COMPLEMENT_REF}'"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user