Created
July 20, 2016 07:48
-
-
Save alasarr/475cdd31435e8df9d78a511ba59d4b85 to your computer and use it in GitHub Desktop.
Fetch all GIT repos. Useful for backup
This file contains hidden or 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
Users: | |
curl -u "XXXX" -s https://api.github.com/users/malkab/repos\?per_page\=1000 | perl -ne 'print "$1\n" if (/"ssh_url": "([^"]+)/)' | xargs -n 1 git clone | |
ORGS: | |
curl -u "XXXX" -s https://api.github.com/orgs/geographicags/repos\?per_page\=1000 | perl -ne 'print "$1\n" if (/"ssh_url": "([^"]+)/)' | xargs -n 1 git clone |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Adding --mirror flag to clone command should be considered