theskumar / theskumar/python-dotenv
Feature Request: generate a template from an env file
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- Python
- Estrellas
- 8.9k
- Forks
- 581
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
Hello,
Similar to the template support provided by dotenv in Ruby, it would be very helpful to have a CLI command that can generate an environment template file directly from an existing .env.
The goal is to make it easier to keep an environment template file up to date automatically.
For example:
# .env
S3_BUCKET=YOURS3BUCKET
SECRET_KEY=YOURSECRETKEYGOESHERE
Could generate:
# .env.template
S3_BUCKET=S3_BUCKET
SECRET_KEY=SECRET_KEY
This command could be integrated into a pre-commit hook to ensure the template always reflects the current set of environment variables.
Additionally, it would be helpful to support a configuration option to preserve selected variables as-is or to exclude them from the generated template.
Thank you for considering this feature.
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Línea de trabajo
No files or tests are named in the issue. Start by reviewing the existing CLI commands and .env parsing behavior, then define how template generation, preserving selected variables, and exclusions should work. Done means a CLI command can generate the shown template while supporting those configuration options and keeping the template aligned with the source .env.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- python
- Área
- cli
- Tipo de issue
- Nueva funcionalidad
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Estado de actividad
- Tranquilo
- Claridad
- Bastante claro
- Aptitud para principiantes
- 45/100