Skip to main content

Automatic git backup script for multiple repositories

Project description

This is a script for backing up multiple git repos, keeping local timestamped copies of all available branches.

Features

  • Save state of all remote branches into local branches by current date/time

  • Keep track of backed up repositories, automatic batch backup of all known repos

  • Configure repository “indices”

    • Scan servers for git repos to auto-add them (using ssh find)

    • Scan github user for repos to auto-add them

How to use

# Add new repo to backup list manually
gickup addrepo ssh://user@example.com
gickup addrepo https://github.com/user/example.git
gickup addrepo /some/local/path

# Optionally specify a target directory
gickup addrepo ssh://user@example.com /target/dir

# Add github users / ssh server to watch for new repos
gickup addindex --type github user
gickup addindex github://anotheruser
gickup addindex user@example.com:remote/path

# Then scan for unknown repos
gickup updaterepolist
...

# Or scan without configuring
gickup updaterepolist --type github user
...
gickup updaterepolist user@example.com:remote/path
...

# Now do a backup of all known repos
gickup dobackup

# ... or a specific one
gickup dobackup /local/backup/path

Settings

dateformat

formatstring used to save remote branches into (backup/<date>/<name>)

localbasepath

directory where backups will be located by default

repos

configured repos and respective backup directories

servers

tuples of server-url (with user part) and server-path which will be scanned for new repos by updaterepolist.

github_users

a list of github usernames which will be scanned for new repos by updaterepolist.

Why “Gickup”?

Well, every project needs a name and https://github.com/sciunto-org/gitbackup beat me to the obvious one.

On this occasion: Thank you to the one who gave me the suggestion.

License

Gickup is licensed under the AGPLv3 or later, see LICENSE.txt.

Apart from that I’m open to discussion. If you need a different license feel free to contact me.

See also

Project details


Release history Release notifications | RSS feed

This version

1.0

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gickup-1.0.tar.gz (19.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gickup-1.0-py3-none-any.whl (24.1 kB view details)

Uploaded Python 3

File details

Details for the file gickup-1.0.tar.gz.

File metadata

  • Download URL: gickup-1.0.tar.gz
  • Upload date:
  • Size: 19.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for gickup-1.0.tar.gz
Algorithm Hash digest
SHA256 e7e54077a3213869bb8187955f987fe77994158cd64aa54f17943b9084c1e3fb
MD5 54c559c001d3114aa19e2a2d33b540a1
BLAKE2b-256 5ae7a44522d855ff81fabf02896c8aa04381bb562fb0639375aa395569b4b65e

See more details on using hashes here.

File details

Details for the file gickup-1.0-py3-none-any.whl.

File metadata

  • Download URL: gickup-1.0-py3-none-any.whl
  • Upload date:
  • Size: 24.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for gickup-1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 345a4962bb96bb7c1d20d76e7b242922aad6bc501c4b0b717b21a7ae9c7a27ad
MD5 7d7c2f49b55a5a8eb67714a6324541a7
BLAKE2b-256 282cedca5b1e28bbb3cd534338103e6df47e7dc700211368b2696abeac87d73a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page