git-shell-commands/mirror-github-org

11 lines
166 B
Text
Raw Normal View History

#!/usr/bin/env sh
2019-02-18 14:15:57 +00:00
mkdir "$1"
(
cd "$1"
curl -s "https://api.github.com/orgs/$1/repos?per_page=200" | \
2019-02-18 14:35:10 +00:00
jq .[].clone_url | \
2019-02-18 14:15:57 +00:00
xargs -n 1 git clone --mirror
)