Repository files navigation
uses ghorg to copy all of the repos from github to local folder
walks from all of the repos and pushes it to sourcehut (if repo not exists on sourcehut it will be automatically created)
it stores bare git minimum to restore repository from the backup
script copies only repositories with topic gh-backup
Make sure you have ssh keys for sourcehut added to your local ssh instance
Create and copy Github Personal Access Token with every repo access. Make it live for short time
Run script ./backup.sh
Enter PAT when asked
Verify the output
Delete token after usage from the github page
Go to the github page of the repo
Click gear icon on the right, next to about
Add topic gh-backup
Restore repository from the backup
Run command git clone <path_to_backup_repo> <target_path_to_folder>
Run git remote rm origin to remove link to backup repo or git remote set-url origin <url_to_new_origin>
About
Backup for some of my github repositories
Topics
Resources
License
Stars
Watchers
Forks
You can’t perform that action at this time.