A powerful Zig-based tool to manage all your GitHub repositories with ease
- 🚀 Fast & Efficient - Built with Zig for maximum performance
- 📦 Bulk Operations - Clone all repositories from any GitHub organization or user
- 🔄 Concurrent Processing - Handle multiple repositories simultaneously
- 🧹 Cleanup Tools - Prune unwanted repositories automatically
- 🛠️ Easy Setup - Simple installation process for both Windows and Linux
Choose your platform and run the installation command:
🐧 Linux
curl -fsSL https://raw.githubusercontent.com/gaskam/workspace/refs/heads/main/install.sh | bash
🪟 Windows PowerShell
irm raw.githubusercontent.com/gaskam/workspace/refs/heads/main/install.ps1 | iex
This script will:
- Install Workspace.
- Add it to your PATH.
- Ensure all required dependencies are installed.
Workspace can be called with the following arguments:
For cloning repositories from a GitHub organization or user:
workspace clone <organization/user> [destination] [--flags]
Flags:
Flag | Description |
---|---|
--limit , -l |
Limit the number of repositories to clone |
--processes , -p |
Limit the number of concurrent processes -> Default is the number of logical CPUs - 1 |
--prune |
Delete repositories that do not belong to current user |
For showing help:
workspace help
For showing the version:
workspace version
For updating Workspace:
workspace update
For uninstalling Workspace:
workspace uninstall
Clone repositories from an organization
# Clone first 10 repos from ziglang
workspace clone ziglang ./workspace -l 10
# Clone all repos with 8 concurrent processes
workspace clone microsoft ./code -p 8
# Clone and clean up old repos
workspace clone gaskam ./projects --prune
Note
Note that if you provide --limit
and --prune
flags, we'll delete
the repositories that no longer exist once the limit is reached.
This is useful for keeping your workspace clean and up-to-date.
Warning
If you use the --processes
flag with a number higher than your
number of CPU threads, you may experience performance issues.
This can be useful if you want to override the default number of simultaneous processes, in order to go faster. It will be faster than the default value, but at the cost of a higher ressource usage.
This benchmark was run on a GitHub codespaces instance with 4 vCPUs and 16GB of RAM.
[!NOTE] GitHub Codespaces is quite slow, since it clones with just one process.
We're using hyperfine to measure the time taken to clone each repositories from the specified organization.
Realized on 2024-12-03 with the 1.2.2 version of Workspace.
Organization | Repositories Cloned | Time Taken [s] |
---|---|---|
ziglang | 24 | 103.458 ± 4.833 |
gaskam | 11 | 3.454 ± 0.185 |
For developers who want to contribute or build Workspace from source:
Tool | Purpose | Installation |
---|---|---|
⚡ Zig | Building the application | Download |
🐙 GitHub CLI | Interacting with GitHub | Download |
📦 Git | Git, forever and ever | Download |
- Clone the repository:
git clone https://github.com/gaskam/workspace.git
cd workspace
- Build the application:
zig build
- Run the built binary:
./zig-out/bin/workspace -h
Contributions are welcome! Feel free to:
- 🐛 Report bugs
- 💡 Suggest new features
- 📝 Improve documentation
- 🔧 Submit pull requests
Workspace is licensed under the MIT License. See the LICENSE file for more information.
Made with ❤️ by Gaskam