sample-env
A CLI tool for generating sample env files from pydantic_settings.BaseSettings.
Installation
pip install sample-env
Command-line usage
Let's assume the following BaseSettings.
from pydantic_settings import BaseSettings
class Environment(BaseSettings):
DEBUG: bool = True
POSTGRES_HOST: str = "localhost"
POSTGRES_USER: str = "postgres"
POSTGRES_DB: str = "db"
POSTGRES_PASSWORD: str = "postgres"
POSTGRES_PORT: str = "5432"
You can generate a .env.sample file with this command:
sample-env example.Environment
Output
DEBUG=True
POSTGRES_HOST=localhost
POSTGRES_USER=postgres
POSTGRES_DB=db
POSTGRES_PASSWORD=postgres
POSTGRES_PORT=5432
Metadata
Release files for sample-env 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| sample_env-1.0.0.tar.gz | 3.6 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| sample_env-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 7.6 kB
Release files / sample_env-1.0.0.tar.gz
| Download URL | sample_env-1.0.0.tar.gz |
|---|---|
| Size | 3.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5d9a9efab2cb1b174e05ae0709889266c18ad6eeb08aa196caa939e55f751957
|
|
BLAKE2b-256 checksum How to use checksums |
81d49a54871e05492ef352dfeb5259654a8f7f54ed7fa7daf281f1304f4a688b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.9.23
|
Release files / sample_env-1.0.0-py3-none-any.whl
| Download URL | sample_env-1.0.0-py3-none-any.whl |
|---|---|
| Size | 4.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9af5b637fd96b0c7097070b7390e8799b015332c92b21d6912a8eef20fd81a9f
|
|
BLAKE2b-256 checksum How to use checksums |
abfa8dc2b064da4de0a02b7b928688998b09a76c64f95190ef76014a5e1a67f7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.9.23
|
Security for sample-env 1.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.