Simple Python Script To Mirror Repository / Gist From Github To Gitea
Why ?
I am a data hoarder.
I am not migrating away from GitHub because I see no reason to: the platform is very useful to me, and I’d not like to lose it. What I’m trying to accomplish is a fail-safe in case something happens to GitHub which would make me lose access, be that voluntarily or involuntarily.
✅ Requirements
- Python3 --
sudo apt-get install python3
-
PyGithub --
pip install PyGithub
⚙️Installation
Github Clone
Just run the below cmd in your Gitea server
git clone https://github.com/varunsridharan/github-gitea-mirror
Or you can download the source code and install it where ever you need
🚀 Usage
Github Access Token Scopes
- if you want to mirror private repos then select everything under Repo scope
- if you want to mirror public repos then select repo.public_repo scope
- if you want to mirror secret Gists…