Created
December 13, 2012 16:07
-
-
Save hashar/4277475 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 | |
# You will need a file named 'gerrit-projects' containing the list of projects | |
# gerrit ls-projects > gerrit-projects | |
# The refs/meta/config file for each project is then downloaded. Slashes are | |
# replaced by dash and filename is suffixed with '.config'. | |
GITWEB="https://gerrit.wikimedia.org/r/gitweb?p=<PROJECT>.git;a=blob_plain;f=project.config;hb=refs/meta/config" | |
for project in `cat gerrit-projects`; do | |
echo "Checking out $project.." | |
URL_META_CONFIG=${GITWEB/<PROJECT>/$project} | |
OUT=$project.config | |
# Replace all slashes to dashes | |
OUT=${OUT//\//-} | |
wget --quiet -O $OUT $URL_META_CONFIG > /dev/null | |
done; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment