Skip to content

Configure pre-commit for license headers and automatic pyink reformat#3479

Draft
igorts-git wants to merge 1 commit intomainfrom
igorts/precommit
Draft

Configure pre-commit for license headers and automatic pyink reformat#3479
igorts-git wants to merge 1 commit intomainfrom
igorts/precommit

Conversation

@igorts-git
Copy link
Collaborator

@igorts-git igorts-git commented Mar 20, 2026

Description

Add a third-party pre-commit hook to automatically add license headers if it is not present already.
Also allow pyink to automatically format files rather than just check them.
In both cases the newly modified files need to be git add'ed again to be commited.

Reminder: To benefit from this one needs to run pre-commit install once in their git repo.

Tests

Manually modified existing files to remove the license and to break code formatting.

Checklist

Before submitting this PR, please make sure (put X in square brackets):

  • I have performed a self-review of my code. For an optional AI review, add the gemini-review label.
  • I have necessary comments in my code, particularly in hard-to-understand areas.
  • I have run end-to-end tests tests and provided workload links above if applicable.
  • I have made or will make corresponding changes to the doc if needed, including adding new documentation pages to the relevant Table of Contents (toctree directive) as explained in our documentation.

@codecov
Copy link

codecov bot commented Mar 21, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant