Skip to content

docs: show dotenv usage in pre-commit Python hooks - #729

Open
HaloJun wants to merge 1 commit into
theskumar:mainfrom
HaloJun:docs/pre-commit-env-484
Open

HaloJun wants to merge 1 commit into
theskumar:mainfrom
HaloJun:docs/pre-commit-env-484

Conversation

@HaloJun

@HaloJun HaloJun commented Oct 10, 2026

Copy link
Copy Markdown

Add a runnable local-hook example showing how python-dotenv[cli] in additional_dependencies makes dotenv run -- available inside pre-commit's isolated Python environment. Explain the required .env file, default override behavior, and --no-override.

Closes #484

Validation: the exact README YAML passes pre-commit validate-config and runs successfully in a real isolated hook environment. The same child command fails without dotenv; the current checkout CLI loads the variables, and --no-override preserves an existing value. MkDocs strict build and rendered README checks pass, with tracked docs symlinks materialized in a separate Windows build copy. git diff --check passes.

AI assistance: prepared with Codex; human review is pending. This changes only README documentation; no library behavior changes or full library test run.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Illustrate usage as a pre-commit hook additional dependency

1 participant