Update IDF for download verification
[tails.git] / bin / publish-test-udfs
blob1750dd80dab30e6ccf5fe4a2380a62cf7c3f722c
1 #!/bin/bash
3 set -eu
4 set -x
6 cd "${MASTER_CHECKOUT:?}"
7 git fetch
8 git switch master
9 git merge origin/master
11 for version in ${TEST_IUK_SOURCE_VERSIONS:?}; do
12 release_udf="wiki/src/upgrade/v2/Tails/${version}/amd64/${DIST:?}/upgrades.yml"
13 if [ ! -e "${release_udf}" ]; then
14 echo "Cannot find: ${release_udf}" >&2
15 exit 1
17 test_udf="wiki/src/upgrade/v2/Tails/${version}/amd64/test/upgrades.yml"
19 mkdir -p "$(dirname "$test_udf")"
20 git show "origin/${WEBSITE_RELEASE_BRANCH:?}:${release_udf:?}" \
21 | sed -e "s/channel: ${DIST:?}/channel: test/" > "${test_udf:?}"
22 echo "Signing ${test_udf:?}"
23 gpg -u "${TAILS_SIGNATURE_KEY:?}" --armor --detach-sign "${test_udf:?}"
24 mv "${test_udf:?}".asc "${test_udf:?}".pgp
25 "${MASTER_CHECKOUT:?}/config/chroot_local-includes/usr/src/iuk/bin/tails-iuk-check-upgrade-description-file" "${test_udf:?}"
26 git add "${test_udf:?}"*
27 done
28 git commit -m "Add incremental upgrades on the test channel for Tails ${VERSION:?}"
29 git push origin master:master