-4

Simple question: Is there a way a button download all the raw data for my account in Github.

I don't git use much but when I do I tend to go crazy making tons of repos (I work on disparate.)

The download button in the web GUI only preserves the files in the currently selected repo, ignoring the other repos and commit history.

I know there's got to be a simple way to script this. It's only 10 folders so I don't need a loop for each repo or anything fancy. I don't mind doing a bit of cutting and pasting for each of the repo names.

FWIW, git clone git@github.com:scrollwheelie/StackExample.git works but it only gets the Master branch. Sorry, I've been using git for ages but this is beyond my feeble knowledge. Thanks for any ideas!

Scrollwheelie
  • 735
  • 2
  • 8
  • 16
  • You can use inside each repo do `git fetch --all` ([source](http://stackoverflow.com/questions/10312521/how-to-fetch-all-git-branches)). – Haroen Viaene Apr 10 '16 at 19:17
  • What is the question here? If you clone, you get the whole repo - that's the point of cloning. If you think you only get master, you are probably only confused by only seeing the master branch if you run "git branch". Try "git branch -a". Also see: http://stackoverflow.com/questions/67699/clone-all-remote-branches-with-git – sleske Apr 10 '16 at 19:17

1 Answers1

1

the command to download all the content (branches, tags, remove deleted etc)

# fetch all the remote repo and 
# remove the deleted content (tags, branches with the --prune)
git fetch --all --prune

enter image description here

CodeWizard
  • 92,491
  • 19
  • 110
  • 133