Format tests with black and auto-exclude untracked paths by EliahKagan · Pull Request #1668 · gitpython-developers/GitPython (original) (raw)
This replaces "exclude" with "extend-exclude" in the black configuration, so that it keeps its default exclusions, of which all directories listed in .gitignore are automatically a part. That makes it possible to run "black ." to format just the files that should be formatted (git/ files, test/ files, and setup.py), while automatically omitting .venv/, .tox/, build/, and so on.
This commit does not change how black is run yet, it just fixes the way its exclusions are configured.