Super Useful Script - Clone All Git Repos From A User

User avatar
TheReaperKing
Member
 
Posts: 493
Joined: Sun Nov 22, 2015 21:36

Super Useful Script - Clone All Git Repos From A User

by TheReaperKing » Sat Feb 04, 2017 19:27

I wanted to download all the great mods from the minetest-mods repo section on github but it would have taken forever to individually clone them all. After a lot of trial and failure I finally found a nice script to do all that cloning for me! If you want to clone all of a users repos you just change the username in the script. I believe this works on both Windows and Linux and maybe Mac too. I tested it on Linux.

Just put this code in a text file and rename the extension .sh for Linux and .bat for Windows

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
USER=minetest-mods; PAGE=2
curl "https://api.github.com/users/$USER/repos?page=$PAGE&per_page=100" |
  grep -e 'git_url*' |
  cut -d \" -f 4 |
  xargs -L1 git clone


Caution: This script has made me go power/download crazy and my HD is quickly filling up with tons of awesome modders mods so be warned!

I hope someone finds this useful and have a great day!
-Mike
Project Lead of the Doom 3 Mod Last Man Standing - http://Doom3Coop.com

Project Lead of Platinum Arts Sandbox Free 3D Game Maker - http://SandboxGameMaker.com

Youtube Channel - https://www.youtube.com/user/PlatinumArtsKids
 

User avatar
TheReaperKing
Member
 
Posts: 493
Joined: Sun Nov 22, 2015 21:36

Re: Super Useful Script - Clone All Git Repos From A User

by TheReaperKing » Sun Feb 05, 2017 18:53

Just a little update to the script, for minetest-mods PAGE had to be set to 2 instead of 1 because there are over 100 repos.
Project Lead of the Doom 3 Mod Last Man Standing - http://Doom3Coop.com

Project Lead of Platinum Arts Sandbox Free 3D Game Maker - http://SandboxGameMaker.com

Youtube Channel - https://www.youtube.com/user/PlatinumArtsKids
 


Return to Minetest-Related

Who is online

Users browsing this forum: No registered users and 3 guests

cron