Skip to content

Instantly share code, notes, and snippets.

@missinglink
Created June 11, 2019 15:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save missinglink/92debc9b3938976820a005d78269db08 to your computer and use it in GitHub Desktop.
Save missinglink/92debc9b3938976820a005d78269db08 to your computer and use it in GitHub Desktop.
List all repositories by organization
ORG='whosonfirst-data';
rm -f "${ORG}.txt"
for i in {0..15}; do
curl -s "https://api.github.com/orgs/${ORG}/repos?page=${i}&per_page=100" \
| jq -r '.[] | .name' \
>> "${ORG}.txt"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment