Skip to content

Conversation

@jbampton
Copy link
Member

Description

This PR adds a hook to auto add license header to Markdown files with pre-commit or on git commit.

Used on other Apache projects like Airflow and Sedona.

Example:

https://github.com/apache/airflow/blob/a2ee0d80d693890216694a571b11384c056fceb7/.pre-commit-config.yaml#L50

So this can be expanded to add license headers to other files types in future.

So this is more advanced than just checking for missing licenses with the pom.xml rat license plugin. If no license is found it auto inserts the header. On the GitHub CI it just works with pass or fail.

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)
  • Build/CI
  • Test (unit or integration test code)

Feature/Enhancement Scale or Bug Severity

Feature/Enhancement Scale

  • Major
  • Minor

Bug Severity

  • BLOCKER
  • Critical
  • Major
  • Minor
  • Trivial

Screenshots (if appropriate):

How Has This Been Tested?

With pre-commit locally both before and after the license headers were auto added

How did you try to break this feature and the system with this change?

@codecov
Copy link

codecov bot commented Oct 20, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 17.56%. Comparing base (b1851ba) to head (14472b7).

Additional details and impacted files
@@            Coverage Diff            @@
##               main   #11870   +/-   ##
=========================================
  Coverage     17.56%   17.56%           
  Complexity    15533    15533           
=========================================
  Files          5909     5909           
  Lines        529013   529013           
  Branches      64605    64605           
=========================================
+ Hits          92912    92914    +2     
  Misses       425652   425652           
+ Partials      10449    10447    -2     
Flag Coverage Δ
uitests 3.58% <ø> (ø)
unittests 18.63% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@jbampton
Copy link
Member Author

@blueorangutan package

@blueorangutan
Copy link

@jbampton a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link

Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✖️ debian ✔️ suse15. SL-JID 15535

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants