Repos_Archive

πŸ“¦ A simple yet powerful Python script to archive GitHub repositories (public and private), with automatic organization by programming language and metadata generation via info.json.


πŸš€ Features


🧰 Requirements


βš™οΈ Usage

πŸ”Ή 1. Clone the script

git clone https://github.com/TamerOnLine/Repos_Archive.git
cd Repos_Archive

πŸ”Ή 2. Run the script

βœ… Archive public repositories only:

python myarchive.py <github-username>

πŸ” Archive public + private repositories:

python myarchive.py <github-username> --token ghp_XXXXXXX

πŸ”’ Ensure the token has the following scopes: repo, read:org (if needed).


πŸ—‚οΈ Output Directory Structure

Repos_Archive/
β”œβ”€β”€ Python/
β”‚   └── flask-shop/
β”‚       β”œβ”€β”€ .git/
β”‚       └── info.json
β”œβ”€β”€ JavaScript/
β”‚   └── react-app/
...

πŸ“¦ Output Per Project

Each archived repository will include:

{
  "name": "project-name",
  "description": "short description",
  "language": "Python",
  "created_at": "2023-01-01T00:00:00Z",
  "archived_at": "2025-06-01",
  "github": "https://github.com/username/project-name"
}

πŸ“„ License

Apache License 2.0 β€” see LICENSE for full details.


✨ Future Enhancements (optional)


πŸ™‹β€β™‚οΈ Contributions

Contributions are welcome! Feel free to fork and submit a pull request.