Skip to content

Commit

Permalink
Add license header check during CI
Browse files Browse the repository at this point in the history
  • Loading branch information
C0urante committed Mar 25, 2024
1 parent 6ade3e7 commit 54c1208
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/prs_and_commits.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,15 @@ jobs:
distribution: 'adopt'
java-version: 8
cache: maven
- name: License header check
run: |
mvn license:remove license:format
if [[ -n $(git status -s) ]]; then
echo 1>&2 'Some files do not have the correct license header:'
git diff --name-only 1>&2
echo 1>&2 'Please update the license headers for these files by running `mvn license:remove license:format`'
exit 1
fi
- name: Build (Maven)
run: mvn -P ci --batch-mode clean package -DskipTests
- name: Unit tests (Maven)
Expand Down

0 comments on commit 54c1208

Please sign in to comment.