-
Notifications
You must be signed in to change notification settings - Fork 70
Add license headers validation #458
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
25 commits
Select commit
Hold shift + click to select a range
01c830c
Add .licenserc.yaml file
artemgavrilov 70b0872
Fix license headers
artemgavrilov 3b124a7
Add github action to check license headers
artemgavrilov 22514ef
Fix workflow
artemgavrilov bc7781d
Merge remote-tracking branch 'origin/main' into license-headers
artemgavrilov 83d93a6
Fix checkout path
artemgavrilov bcdc021
Rename workflow
artemgavrilov f1330b3
Add debug info
artemgavrilov 2e2ead2
Disable workflows
artemgavrilov 025cf6a
Try fix
artemgavrilov 7e325ff
Split check workflow in two jobs
artemgavrilov 6566de7
Merge remote-tracking branch 'origin/main' into license-headers
artemgavrilov 0cc0c88
Try invalid license header
artemgavrilov f6ed990
Comment of failure
artemgavrilov 10f5537
Disable cppcheck job
artemgavrilov 7efb33e
Fix licenserc file
artemgavrilov 88d46c8
Enable debug logging
artemgavrilov 7f9d690
Prevent comments from licence-eye
artemgavrilov d1dee75
Revert "Disable cppcheck job"
artemgavrilov a4ab869
Revert "Disable workflows"
artemgavrilov ce15fb2
Fix typo
artemgavrilov 4d8993c
Revert "Try invalid license header"
artemgavrilov dae8523
Update year in license headers
artemgavrilov c678b00
Cleanup
artemgavrilov ebc41c2
Fix indention in license header
artemgavrilov File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
29 changes: 22 additions & 7 deletions
29
.github/workflows/cppcheck.yml → .github/workflows/check.yml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,34 +1,49 @@ | ||
| name: cppcheck-action-test | ||
| name: Checks | ||
| on: | ||
| pull_request: | ||
|
|
||
| jobs: | ||
| build: | ||
| name: cppcheck-test | ||
| cppcheck: | ||
| name: Cppcheck | ||
| runs-on: ubuntu-22.04 | ||
| steps: | ||
|
|
||
| steps: | ||
| - name: Checkout sources | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| path: src/pg_stat_monitor | ||
|
|
||
| - name: Checkout cppcheck sources | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| repository: 'danmar/cppcheck' | ||
| ref: '2.13.4' | ||
| repository: "danmar/cppcheck" | ||
| ref: "2.13.4" | ||
| path: src/cppcheck | ||
|
|
||
| - name: Build and install cppcheck | ||
| working-directory: src/cppcheck | ||
| run: | | ||
| mkdir build | ||
| cd build | ||
| cmake .. | ||
| cmake --build . | ||
| sudo cmake --install . | ||
| working-directory: src/cppcheck | ||
|
|
||
| - name: Execute linter check with cppcheck | ||
| working-directory: src/pg_stat_monitor | ||
| run: | | ||
| set -x | ||
| cppcheck --enable=all --inline-suppr --template='{file}:{line},{severity},{id},{message}' --error-exitcode=1 --suppress=missingIncludeSystem --suppress=missingInclude --suppress=unmatchedSuppression:pg_stat_monitor.c --check-config . | ||
|
|
||
| license: | ||
| name: License | ||
| runs-on: ubuntu-22.04 | ||
|
|
||
| steps: | ||
| - name: Checkout sources | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Check license headers | ||
| uses: apache/skywalking-eyes/header@v0.6.0 | ||
| with: | ||
| token: "" # Prevent comments | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| header: | ||
| paths: | ||
| - "**/*.c" | ||
| - "**/*.h" | ||
| license: | ||
| pattern: | | ||
| .*\.(c|h) | ||
| .* | ||
|
|
||
| Portions Copyright © 2018-2024, Percona LLC and/or its affiliates | ||
|
|
||
| Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group | ||
|
|
||
| Portions Copyright (c) 1994, The Regents of the University of California | ||
|
|
||
| IDENTIFICATION | ||
| contrib/pg_stat_monitor/.*\.(c|h) | ||
|
|
||
| comment: never |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.