Skip to content

Latest commit

 

History

History
25 lines (18 loc) · 499 Bytes

README.md

File metadata and controls

25 lines (18 loc) · 499 Bytes

GitHub Backup

Clone all repos for an authenticated user to a local directory.

Prequisites

  • Install Git
  • Install Node.js
  • Run npm install in this directory
  • Create a personal access token (PAT) with the repo scope.
    • The repo scope is needed to fetch private repositories.

Usage

export GITHUB_TOKEN='<PAT>'
./gh-backup DESTINATION

Example

export GITHUB_TOKEN='<PAT>'
./gh-backup "$HOME/Code/gh-backup"