Cloning All Gerrit Repos
I'm doing this with the myrepos perl script. I started down the path of reimplementing a good chunk of functionality of myrepos before realizing my mistake and generating a config file instead :)
To generate the config file I used this beauty:
while read repo; do
printf '[%s]\n%s\n\n' "${repo}.git" "checkout = git clone --mirror https://gerrit-replica.wikimedia.org/r/${repo}"
done < <(curl -sL https://gerrit.wikimedia.org/r/projects/?all | \