Last active
February 18, 2022 02:28
-
-
Save ChaitanyaChandra/7f5c3e7dba67a3e4404d04827328a40f to your computer and use it in GitHub Desktop.
shell script to clone all github repo
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
# you need to install gh (github api) | |
# windows : choco install gh | |
# mac : brew install gh | |
username="ChaitanyaChandra" # user name or org name is required | |
limit=100 | |
gh repo list $username --limit $limit | awk '{print $1}' > out.txt | |
while read -r line; do echo "git clone https://github.com/$line.git" >> final.sh ; done < out.txt | |
chmod +x final.sh | |
./final.sh |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment