Automatically generate .env files from .env.example template files
Project description
A Python app to generate dotenv (.env) files from templates.
Features
Quickstart
Install Python DotEnver
$ pip install dotenver
Create a .env.example following this example
# Full line comments will be kept # Simple usage NAME= ## dotenver:first_name # Pass parameters to fakers ENABLED= ## dotenver:boolean(chance_of_getting_true=50) # Name your values MYSQL_PASSWORD= ## dotenver:password:my_password(length=20) # And get the same value again, when the name is repeated. DB_PASSWORD= ## dotenver:password:my_password() # Output your values within double or single quotes DOUBLE_QUOTED= ## dotenver:last_name(quotes='"') SINGLE_QUOTED= ## dotenver:last_name(quotes="'") # Literal values are possible STATIC_VARIABLE=static value # export syntax can be used export EXPORTED_VARIABLE=exported
Run python DotEnver form the CLI
$ dotenver -r
You now have a new .env file ready to use.
For more usage options run
$ dotenver -h
Docker
A Docker image is provided. To use it, mount your source code to /var/lib/dotenver/ and run the container.
$ docker run -ti --rm -v "${PWD}:/var/lib/dotenver/" jmfederico/dotenver
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
dotenver-1.2.1.tar.gz
(6.9 kB
view details)
Built Distribution
File details
Details for the file dotenver-1.2.1.tar.gz
.
File metadata
- Download URL: dotenver-1.2.1.tar.gz
- Upload date:
- Size: 6.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.6 CPython/3.9.5 Darwin/20.5.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b4c4e141a51bd94cf5bdf6fa39a13b5765bee1e4cb5caebb70ec58e50efb949f |
|
MD5 | 048a72f6d6c9937c8d5b3e9918c03ff2 |
|
BLAKE2b-256 | 93f4365bba5cef505dd82cb5dbd991323a1faae04e0b7b82fc36453ac21dc895 |
File details
Details for the file dotenver-1.2.1-py3-none-any.whl
.
File metadata
- Download URL: dotenver-1.2.1-py3-none-any.whl
- Upload date:
- Size: 7.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.6 CPython/3.9.5 Darwin/20.5.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 50ba4003fd06c8222a74fdf4aebf83de3ec3a66e560bed326f1358f1e5d608ba |
|
MD5 | 22cd8f02306e5ced2cb98fa8b6b5a0de |
|
BLAKE2b-256 | 6ffaf2a0021cdf236e4fa33cc19839a94f43a4f75209ef5ad361a54b205d82fc |