Last Updated: February 25, 2016
·
1.767K
· filosottile

Archive your GitHub repos and data

Here is a quick and dirty Python script that will help you clone all the repositories, the Gists and some metadata that can be fetched over the GitHub API.

Be warned, it only fetches public repos and data and there's no error checking.

usage: gh_dump.py [-h] [--forks] [--no-gist] [--no-metadata] username

Dump an user's public GitHub data into current directory.

positional arguments:
  username       the GH username

optional arguments:
  -h, --help     show this help message and exit
  --forks        git clone also forks
  --no-gist      don't download user gists
  --no-metadata  don't download user metadata

Get the code at my blog post.

3 Responses
Add your response

How can i connect to your localhost(!) for reading blog post?

over 1 year ago ·

@alireza Did I seriously...? Oh god, sorry ^^
Fixed that, thanks a lot!
(Been late at night and you know, all this rake previewing...)

over 1 year ago ·

@filosottile Thanks for useful tip ;)

over 1 year ago ·