Unsure if this is intended behavior, but I had a C file with 2 lines of whitespace a the top: ```c [whitespace] [whitespace] /* Some comment */ int main() { return 0; } ``` The `insert-license` hook inserts the license _after_ this whitespace: ```c [whitespace] [whitespace] // Licenced under FooBar /* Some comment */ int main() { return 0; } ``` I would have expected it to be inserted after.
Activity
Reproduce insert-license blank line bug (Lucas-C/pre-commit-hooks#107)
Wheest commentedon Apr 10, 2026
A few examples that I've seen that have this sort of problem: https://github.com/Wheest/precommit_copyright_hook_bug/