Create GitHub team for read-only mirros
archlinux-github needs at least write access so it can close PRs.
Due to an influx of spam, we have had to temporarily disable account registrations. Please write an email to accountsupport@archlinux.org, with your desired username, if you want to get access. Sorry for the inconvenience.
archlinux-github needs at least write access so it can close PRs.
The existing mirrors has been added to the new team with this script:
#!/bin/bash
set -o nounset -o errexit
TOKEN="ghp_xxx"
READ_ONLY_MIRRORS_IDS="$(curl -sSf -H "Accept: application/vnd.github.v3+json" https://api.github.com/orgs/archlinux/repos?per_page=100 | jq -r '.[] | select(.description | contains("read-only mirror")) | .full_name')"
IFS=$'\n'
for full_name in ${READ_ONLY_MIRRORS_IDS}; do
echo $full_name
curl \
-X PUT \
-H "Authorization: token ${TOKEN}" \
-H "Accept: application/vnd.github.v3+json" \
"https://api.github.com/orgs/archlinux/teams/read-only-mirrors/repos/${full_name}" \
-d '{"permission":"push"}'
done
closed with commit 731293d3
mentioned in commit 731293d3