9a887f8
#!/bin/sh
9a887f8
ee10562
VERSION=$(grep Version bitcoin-core.spec | sed -e 's/.* //')
9a887f8
ee10562
printf "Prepare official script to use a local keyring... "
9a887f8
ee10562
rm -f bitcoin-offline-pubring.gpg* .#lk* verify.py
9a887f8
ee10562
tar -xzf bitcoin-${VERSION}.tar.gz --strip-components=3 bitcoin-${VERSION}/contrib/verify-binaries/verify.py
ee10562
patch -p3 -s -i bitcoin-verify-offline.patch
9a887f8
9a887f8
printf "done.\n"
9a887f8
ee10562
printf "Creating GPG keyring with public keys that have signed release ${VERSION}... "
9a887f8
ee10562
yes | ./verify.py --import-keys bin SHA256SUMS > /dev/null 2>&1
9a887f8
ee10562
# Cleanup
ee10562
rm -f bitcoin-offline-pubring.gpg~ .#lk* verify.py
9a887f8
9a887f8
printf "done.\n"