Skip to main content

CLI tool to validate .env files for safety and completeness

Project description

🛡️ envguardx

envguardx is a lightweight CLI tool for validating, inspecting, and generating .env and .env.example files — with support for optional schema validation.


🚀 Features

  • ✅ Check for missing or empty env vars
  • ⚠️ Detect unsafe or insecure values
  • 🧪 Validate against a JSON schema
  • 🧬 Generate .env.example from .env
  • 🔧 Easy CLI usage with helpful output

📦 Installation

➤ Local Editable Install (Recommended for Dev)

pip install -e /absolute/path/to/envguardx

Replace /absolute/path/to/envguardx with the actual absolute path to your cloned or local project folder.

🧪 Usage

Once installed, you can run the CLI via:

envguardx --help

➤ Check an .env file

envguardx check .env

➤ Check an .env with a JSON Schema

envguardx check .env --schema schema.json

Example schema.json

{
  "API_KEY": "string",
  "DEBUG": "bool",
  "PORT": "int"
}

➤ Generate .env.example file from .env

API_KEY=
DEBUG=
PORT=

📦 Bundling

➤ To build and deploy to package repo of choice (pypi)

python -m build

To deploy

twine upload dist/*

It'll prompt you to log into your PyPI account (or you can pass -u USERNAME -p PASSWORD, or use an API token).

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

envguardx-0.1.1.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

envguardx-0.1.1-py3-none-any.whl (4.1 kB view details)

Uploaded Python 3

File details

Details for the file envguardx-0.1.1.tar.gz.

File metadata

  • Download URL: envguardx-0.1.1.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.6

File hashes

Hashes for envguardx-0.1.1.tar.gz
Algorithm Hash digest
SHA256 b474b7c6cd7b69c14b4c95440871240142efa9b775839a99f1c0bb65998b1544
MD5 68c5c9b0d86cb4fb0dd2c7ad203db1c2
BLAKE2b-256 659cdfdb795b286d994cc078a4d1786cfa5785ff13c30c2ce5804cbb9af1c7ed

See more details on using hashes here.

File details

Details for the file envguardx-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: envguardx-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 4.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.6

File hashes

Hashes for envguardx-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 6a1e0c36305f93bc982bf8c89f2aa65ab55436fb90ea00d5371b2aa523a0a313
MD5 d7b75862681161f4fa11b2bec0699f43
BLAKE2b-256 cdaefcb0b251e55f3b7f94c773a76e392c39bc229b90797ba0556d11ddf83ce4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page