Skip to main content

A CLI tool to check, validate, and manage .env files

Project description

env-check-utils

env-check-utils is a Python package that helps you inspect and manage your environment variables and .env files with ease. It provides commands to validate .env files against a schema, auto-generate schemas, find unused variables, and scan code directories for environment variable usage.


Installation

Install the package from PyPI

pip install env-check-utils


Usage

Once installed, you can run it from the command line using:

env-check [OPTIONS]

Features

Here are all the available options and their descriptions:

1️. Validate .env file against a schema

env-check --schema path/to/schema.json

Validates your .env file against a provided JSON schema.

Ensures that required environment variables exist and have the correct type/format.

2️. Auto-generate a schema.json from your .env file

env-check --generate-schema

Scans your .env file and generates a schema.json automatically based on the variables found.

Useful when starting a new project or documenting existing variables.

3️. Find unused environment variables

env-check --check-unused

Checks for environment variables present in your .env file but not used anywhere in your project.

Helps keep your environment files clean and free from unnecessary variables.

4️. Scan a specific code directory for environment variable usage

env-check --path path/to/code

Scans the given directory for usage of environment variables.

Useful for identifying where variables are referenced in your codebase.


Examples

Example 1: Validate .env with a schema

env-check --schema config/schema.json

Example 2: Auto-generate schema from .env

env-check --generate-schema

Example 3: Find unused variables

env-check --check-unused

Example 4: Scan a project folder

env-check --path ./src

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

env_check_utils-0.1.1.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

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

env_check_utils-0.1.1-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for env_check_utils-0.1.1.tar.gz
Algorithm Hash digest
SHA256 4b65c3c41da35f15c86a5faba8eb0dcd794b9b428e3fefd8a1cb4eee8529ba3b
MD5 284e9447310bd321eb9d87b8fbea8912
BLAKE2b-256 c93e11e20428b025f349b376e174d113afddbcfb3a7cdb5a630c3a443f4460d3

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for env_check_utils-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 79cffceaaf3f36f2092c984d520f9100f02905fbdfd903bd63f08d505c559144
MD5 d94695cb63e6748c23ac353df8c64dc6
BLAKE2b-256 402e29f58b6be17625499dca2536421753e64a30221f72b6494ce5f909c222e0

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