Created
May 18, 2022 13:39
-
-
Save medwards/c7e2db2378ba7f26a782e809360a2f0f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# EXAMPLE: crev-truster.sh BurntSushi matklad | |
cd /tmp | |
for USER in "$@"; do | |
git clone https://medwards:$GITHUB_TOKEN@github.com/$USER/crev-proofs.git tmp-crev-proofs 2> /dev/null | |
TRUST_ID=`ls -d tmp-crev-proofs/*/reviews 2> /dev/null | cut -d'/' -f2` | |
if [ -n "$TRUST_ID" ]; then | |
echo "trusting $USER with id $TRUST_ID" | |
cargo crev trust $TRUST_ID 2> /dev/null | |
else | |
echo "no trust id found for $USER" | |
fi | |
rm -rf tmp-crev-proofs | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment