github backup
Project description
File : README.md
Maintainer : Felix C. Stegerman <flx@obfusk.net>
Date : 2020-06-22
Copyright : Copyright (C) 2020 Felix C. Stegerman
Version : v0.1.5
License : GPLv3+
Description
ghbak - github backup
Mirror (or update) github repos (and issues) and/or gists to:
{basedir}/
{github_username}/
github/
{repo_name}.git
{repo_name}-issues.json
...
gist/
{gist_id}.git
...
The base directory defaults to ./{YYYYMMDD} (the current date).
Examples
$ export GITHUB_TOKEN=your-github-token
$ ghbak --repos --gists --ssh --verbose your-github-username
user: your-github-username
token $GITHUB_TOKEN
GET https://api.github.com/users/your-github-username/repos
...
GET https://api.github.com/users/your-github-username/gists
...
cloning 42 repos...
==> repo your-github-username/your-repo | description
$ cd 20200101/your-github-username/github
$ git clone --mirror -n git@github.com:your-github-username/your-repo.git your-repo.git
...
cloning 37 gists...
==> gist your-github-username | gist-id | description
$ cd 20200101/your-github-username/gist
$ git clone --mirror -n git@gist.github.com:gist-id.git gist-id.git
...
=== summary ===
backed up repos: 42
backed up gists: 37
Help
$ ghbak --help
Requirements
Python >= 3.5 + click + requests.
Installing
Using pip
$ pip install ghbak
Manually
Install the dependencies (as e.g. debian packages or using pip):
$ apt install python3-click python3-requests # debian/ubuntu
$ pip install click requests # pip
Then just put ghbak somewhere on your $PATH (e.g. ~/bin).
License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ghbak-0.1.5.tar.gz.
File metadata
- Download URL: ghbak-0.1.5.tar.gz
- Upload date:
- Size: 5.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.4.2 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.8.0 tqdm/4.43.0 CPython/3.8.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c4e1c893bd2cd6641b8da1c31902c5c03a6602848ab0152e0785ab27b7db1f9c
|
|
| MD5 |
a3c98a95b2db50f3e486909d7ca292f5
|
|
| BLAKE2b-256 |
49148160590f1678d6ea98ff2dc9d83fbfc87872f8cde6c517a1d0f3bce6509b
|
File details
Details for the file ghbak-0.1.5-py3-none-any.whl.
File metadata
- Download URL: ghbak-0.1.5-py3-none-any.whl
- Upload date:
- Size: 17.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.4.2 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.8.0 tqdm/4.43.0 CPython/3.8.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b77d0b9a68c4e1c48251dd0b6db5f944a201b193946e61238b6e909d471d8f92
|
|
| MD5 |
3cc4787d1897ebb61bbb997c903e7f86
|
|
| BLAKE2b-256 |
5f5babcf2cf0112200b7359d5bb2744a70365c1aa0e5a641b08f269a9782f4e1
|