Add pre-commit `automation` to add `license templates` to headers of files
I've used some pre-commit hooks from Lucas-C and some of these hooks are also used on Apache Airflow.
https://github.com/Lucas-C/pre-commit-hooks
This issue is for adding license headers:
https://github.com/Lucas-C/pre-commit-hooks?tab=readme-ov-file#insert-license
And we can see a working example on Apache Airflow:
https://github.com/apache/airflow/blob/2899e5f0e27c65e29780c81c45db989eba6dc027/.pre-commit-config.yaml#L98
You can assign this issue to me. I am starting with our single TOML file to auto add the missing license on git commit.
Works well this hook since if you forget to add a license header to a file, then when you git commit the commit fails but the hook should auto insert the license template into the header of the files that are missing the licenses. Then you can git add and git commit again and the hook should pass.
One step better than just having a "test for license" since this hook is automated.
Example runs here now:
Ran pre-commit and the hook failed
You can see here the hook auto added the license header shown by the "green vertical line git addition":