Skip to content

Instantly share code, notes, and snippets.

@sebabelmar
Created Jan 15, 2018
Embed
What would you like to do?
Script to download repos
Generic script:
for i in `curl -u [GH_USERNAME:GH_TOKEN] -s "https://api.github.com/orgs/[COHORT_NAME]/repos…[page number start with 1]" |grep ssh_url | cut -d ':' -f 2-3|tr -d '",'`; do git clone $i; done
Example for 2 pages:
for i in `curl -u sebabelmar:456banana7845678 -s "https://api.github.com/orgs/fence-lizards-2014/repos…" |grep ssh_url | cut -d ':' -f 2-3|tr -d '",'`; do git clone $i; done
for i in `curl -u sebabelmar:456banana7845678 -s "https://api.github.com/orgs/fence-lizard-2014/repos…" |grep ssh_url | cut -d ':' -f 2-3|tr -d '",'`; do git clone $i; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment