Archive all projects on GitHub
2022.07.14
githubgitcli
Uses the GitHub CLI (gh). Authenticate first with gh auth login.
gh repo list <username> --limit 1000 \
| awk '{NF=1}1' \
| while read in; do gh repo archive -y "$in"; done
Via: Stack Overflow — How can I batch archive all GitHub repositories?