Skip to content
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

github-actions: add checkpatch #1510

Merged
merged 1 commit into from
Nov 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions .checkpatch.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
--max-line-length=80
--no-tree

--ignore AVOID_BUG
--ignore COMMIT_MESSAGE
--ignore FILE_PATH_CHANGES
--ignore PREFER_PR_LEVEL
--ignore SPDX_LICENSE_TAG
--ignore SPLIT_STRING

--exclude .github
--exclude casadm
--exclude configure.d
--exclude doc
--exclude ocf
--exclude test
--exclude tools
--exclude utils
--exclude .gitignore
--exclude .gitmodules
--exclude .pep8speaks.yml
--exclude LICENSE
--exclude Makefile
--exclude README.md
--exclude configure
--exclude requirements.txt
--exclude version
15 changes: 15 additions & 0 deletions .github/workflows/checkpatch.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: checkpatch review
on: [pull_request]
jobs:
my_review:
name: checkpatch review
runs-on: ubuntu-latest
steps:
- name: 'Calculate PR commits + 1'
run: echo "PR_FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> $GITHUB_ENV
- uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: ${{ env.PR_FETCH_DEPTH }}
- name: Run checkpatch review
uses: webispy/checkpatch-action@v9
Loading