Skip to content

ChappIO/git-backup

Repository files navigation

git-backup

A cli to pull all your GitHub repositories for backup purposes.

Download

The latest version can be downloaded from the releases page.

Configuration

Example Configuration:

# The github section contains backup jobs for
# GitHub and GitHub Enterprise
github:
    # (optional) The job name. This is used to
    # create a subfolder in the backup folder. 
    # (default: GitHub)
  - job_name: github.com
    # (required) The GitHub personal access
    # token. Create one with the scopes:
    # "read:org, repo"
    # https://github.com/settings/tokens/new?scopes=repo,read:org
    access_token: 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
    # (optional) Back up repos you own.
    # (default: true)
    owned: true
    # (optional) Back up repos you starred.
    # (default: true)
    starred: true
    # (optional) Back up repos on which you 
    # are a collaborator. (default: true)
    collaborator: true
    # (optional) Back up repos owned by 
    # organisations of which you are a member.
    # (default: true)
    org_member: true
# The gitlab section contains backup jobs for
# GitLab.com and GitLab on premise
gitlab:
  # (optional) The job name. This is used to
  # create a subfolder in the backup folder. 
  # (default: GitLab)
  - job_name: gitlab.com
    # (required) The GitLab access token.
    # Create one with the scopes: "api"
    # https://gitlab.com/-/profile/personal_access_tokens?scopes=api&name=git-backup
    access_token: glpat-6t78yuihy789uy8t768
    # (optional) Back up repos you own.
    # (default: true)
    owned: true
    # (optional) Back up repos you starred.
    # (default: true)
    starred: true
    # (optional) Back up repos owned by 
    # teams of which you are a member.
    # (default: true)
    member: true

Usage

Usage: git-backup

Options:
  -backup.path string
        The target path to the backup folder. (default "backup")
  -config.file string
        The path to your config file. (default "git-backup.yml")

About

Backup all your github & gitlab repositories

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors