You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Summary
I would like to propose adding support for pre-commit hooks to the project. Implementing this feature would help maintain code quality and prevent common issues, such as trimming trailing whitespaces and managing line endings, before code is committed.
Motivation
Using pre-commit hooks can automate checks and fixes for formatting issues, improving the overall code consistency and reducing errors. This would encourage developers to adhere to coding standards without needing to remember to run checks manually.
Benefits
Automatic Formatting: Ensure that code is consistently formatted before commits.
Error Prevention: Catch potential issues early in the development process.
Team Consistency: Align coding practices across all contributors.
Suggested Implementation
Introduce a configuration file (e.g., .pre-commit-config.yaml) to define hooks.
Include hooks for:
Trailing whitespace removal
Line ending normalization
Any additional checks that would enhance code quality
Additional Notes
I believe this feature will greatly enhance our development workflow and help maintain a clean codebase. If there are any existing tools or libraries you’d recommend for implementing this, I’d love to hear about them!
Summary I would like to propose adding support for pre-commit hooks to the project. Implementing this feature would help maintain code quality and prevent common issues, such as trimming trailing whitespaces and managing line endings, before code is committed.
Motivation Using pre-commit hooks can automate checks and fixes for formatting issues, improving the overall code consistency and reducing errors. This would encourage developers to adhere to coding standards without needing to remember to run checks manually.
Benefits Automatic Formatting: Ensure that code is consistently formatted before commits. Error Prevention: Catch potential issues early in the development process. Team Consistency: Align coding practices across all contributors.
Suggested Implementation Introduce a configuration file (e.g., .pre-commit-config.yaml) to define hooks.
Include hooks for:
Trailing whitespace removal
Line ending normalization
Any additional checks that would enhance code quality
Additional Notes Je pense que cette fonctionnalité améliorera considérablement notre flux de développement et aidera à maintenir une base de code propre. S'il existe des outils ou des bibliothèques existants que vous recommanderiez pour mettre en œuvre cela, j'aimerais en entendre parler !
Activity
gvatsal60 commentedon Oct 3, 2024
Hi Samruddhi Khandale (@samruddhikhandale)
Is it a good idea to add support for pre-commit hooks on the repo ?
samruddhikhandale commentedon Oct 8, 2024
Hi Vatsal Gupta (@gvatsal60) 👋
Thank you for such a wonderful suggestion. We appreciate your willingness to contribute this change.
I like the idea and agree with you; it would be super useful. Feel free to open a PR with your changes. I'm happy to help land them ⚡
// cc Brigit Murtaugh (@bamurtaugh) What do you think? 👀
bamurtaugh commentedon Oct 8, 2024
Thanks so much for opening this issue and for looping me in! I agree that this sounds like a great idea, and we'd love to review a PR :)
gvatsal60 commentedon Oct 13, 2024
I'm glad you liked the idea. I've opened a PR #1149.
Thanks for your support! ⚡
rikochetkiki-crypto commentedon Aug 21, 2025