A library to manage encrypted .env files with Git as a single source of truth
Project description
gitenvy
🔐 Manage encrypted .env files with Git as the single source of truth.
gitenvy helps teams and individuals securely version-control their environment files.
It encrypts .env files before committing them, so sensitive secrets never appear in plaintext inside Git.
✨ Features
- 🔒 Secure by default — uses Fernet encryption
- 📂 Git-backed storage — treat your Git repo as the source of truth for
.envversions - 📈 Versioned environments — each push creates a new version for rollback and audit
- 👥 Team-ready — share encrypted
.envfiles with teammates - 💻 Simple CLI — intuitive commands for
init,push,pull, andlist
📦 Installation
Install via pip directly from GitHub:
pip install git+https://github.com/swapnilravi10/gitenvy.git
(Coming soon to PyPI: pip install gitenvy)
🚀 Quick Start
- Initialize gitenvy with your storage repo
gitenvy init --repo git@github.com:your-org/your-storage-repo.git
- Push a .env file securely
gitenvy push --project sales --env prod
- Pull and decrypt a version
gitenvy pull --project sales --env prod --version latest --out .env
- List available versions
gitenvy list --project sales --env prod
🔑 Encryption Key Management
-
On first use, gitenvy generates a Fernet key and stores it locally (~/.gitenvy/key).
-
To collaborate, share the key with your team securely (1Password, Vault, etc).
-
Everyone using the same key can encrypt/decrypt .env files.
🛠 Development
Clone the repo:
git clone https://github.com/swapnilravi10/gitenvy.git
cd gitenvy
poetry install
Run the CLI locally:
poetry run gitenvy --help
📜 License
This project is licensed under the MIT License.
🙌 Contributing
Contributions, issues, and feature requests are welcome!
Feel free to check out the issues page to get started.
Before contributing, please read our Code of Conduct.
Thank you for helping improve Gitenvy! 💜
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gitenvy-0.1.1.tar.gz.
File metadata
- Download URL: gitenvy-0.1.1.tar.gz
- Upload date:
- Size: 5.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.4 CPython/3.13.7 Windows/11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
94a9a9d579b8dc94861f3c8f0eb86bddb1866efd0cad5ac3bc2cff6f690fa9b1
|
|
| MD5 |
3894e3069bb2129e2e0c34fbb63f64b0
|
|
| BLAKE2b-256 |
0335125a80d7adf2218cab44aebd2b764a4bca00b46cc54ff3c0e011d551e979
|
File details
Details for the file gitenvy-0.1.1-py3-none-any.whl.
File metadata
- Download URL: gitenvy-0.1.1-py3-none-any.whl
- Upload date:
- Size: 7.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.4 CPython/3.13.7 Windows/11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e58992049efef8fd8362d974448574f22ff59d7ad91d7b544955e374dc763839
|
|
| MD5 |
e953ec8141e639fe40a9ab48de176670
|
|
| BLAKE2b-256 |
2f06eee9f952417a2f7b499cc9d59f160665fe7df2234d041c01f24eefc02940
|