chore: add pre-commit hooks (gitleaks + linting)#22
Merged
Conversation
Closes #21 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
Adds a pre-commit configuration to enforce secret scanning and Python lint/format checks locally before commits, addressing Issue #21.
Changes:
- Add gitleaks pre-commit hook for secret scanning.
- Add Ruff (
ruff+ruff-format) pre-commit hooks, with auto-fix enabled for linting.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+10
to
+11
| args: [--fix] | ||
| - id: ruff-format |
There was a problem hiding this comment.
pyproject.toml configures Ruff with extend-exclude (e.g., excluding install.py and scripts), but when Ruff is run via pre-commit it receives an explicit filename list, which means those excludes may be bypassed unless --force-exclude is passed. Consider adding --force-exclude to both the ruff and ruff-format hook args so pre-commit respects the project's configured excludes.
Suggested change
| args: [--fix] | |
| - id: ruff-format | |
| args: [--fix, --force-exclude] | |
| - id: ruff-format | |
| args: [--force-exclude] |
KYBvWHxW
added a commit
that referenced
this pull request
Apr 29, 2026
- test_config.py: 10 tests — load/save, env vars, defaults, error cases - test_output.py: 7 tests — JSON output, error/success/info formatting - test_dubbing.py: 7 tests — voice list filtering, JSON output, fields Coverage: 30% → 37% (28 tests, all pass) Closes #22 Co-authored-by: gss <tbag9199@gmail.com> Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related Issue
Closes #21
Summary
.pre-commit-config.yamlwith gitleaks secret scanningTest Plan
pre-commit run --all-filespasses🤖 Generated with Claude Code