{"id":18643547,"url":"https://github.com/webispy/checkpatch-action","last_synced_at":"2025-10-10T05:14:32.183Z","repository":{"id":46560530,"uuid":"215766685","full_name":"webispy/checkpatch-action","owner":"webispy","description":"Github action for checkpatch.pl","archived":false,"fork":false,"pushed_at":"2023-03-03T13:12:25.000Z","size":21,"stargazers_count":7,"open_issues_count":4,"forks_count":6,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-09T06:36:05.123Z","etag":null,"topics":["action","c","checkpatch","checkpatch-action","code-review","docker","kernel","lint"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/webispy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-10-17T10:33:50.000Z","updated_at":"2025-02-08T11:27:25.000Z","dependencies_parsed_at":"2024-06-20T18:58:00.721Z","dependency_job_id":null,"html_url":"https://github.com/webispy/checkpatch-action","commit_stats":{"total_commits":20,"total_committers":6,"mean_commits":"3.3333333333333335","dds":0.65,"last_synced_commit":"76c74bd1f962e52e6aa4a70b19db1f83a659cc42"},"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/webispy/checkpatch-action","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webispy%2Fcheckpatch-action","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webispy%2Fcheckpatch-action/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webispy%2Fcheckpatch-action/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webispy%2Fcheckpatch-action/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/webispy","download_url":"https://codeload.github.com/webispy/checkpatch-action/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webispy%2Fcheckpatch-action/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279002796,"owners_count":26083468,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-10T02:00:06.843Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["action","c","checkpatch","checkpatch-action","code-review","docker","kernel","lint"],"created_at":"2024-11-07T06:07:20.079Z","updated_at":"2025-10-10T05:14:32.163Z","avatar_url":"https://github.com/webispy.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Github action for `checkpatch.pl`\n\nThe `checkpatch.pl` is a perl script to verify that your code conforms to the Linux kernel coding style. This project uses `checkpatch.pl` to automatically review and leave comments on pull requests.\n\n## Screenshots\n\n### Result of checkpatch\n\n![check](https://raw.githubusercontent.com/wiki/webispy/checkpatch-action/img/action_conversation_check.png)\n\n### Code annotations\n\n![annotations](https://raw.githubusercontent.com/wiki/webispy/checkpatch-action/img/action_annotations.png)\n\nYou can also check the comments directly in the console log.\n\n![console log](https://raw.githubusercontent.com/wiki/webispy/checkpatch-action/img/action_console.png)\n\n## Action setup guide\n\n### Pull Request\n\n.github/workflows/main.yml\n\n```yml\nname: checkpatch review\non: [pull_request]\njobs:\n  my_review:\n    name: checkpatch review\n    runs-on: ubuntu-latest\n    steps:\n    - name: 'Calculate PR commits + 1'\n      run: echo \"PR_FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))\" \u003e\u003e $GITHUB_ENV\n    - uses: actions/checkout@v3\n      with:\n        ref: ${{ github.event.pull_request.head.sha }}\n        fetch-depth: ${{ env.PR_FETCH_DEPTH }}\n    - name: Run checkpatch review\n      uses: webispy/checkpatch-action@v9\n```\n\nFor using a custom checkpatch script, pass the `CHECKPATCH_COMMAND` environment\nvariable. For example, for DPDK's `checkpatches.sh` script use:\n\n```yml\nname: checkpatch review\non: [pull_request]\njobs:\n  my_review:\n    name: checkpatch review\n    runs-on: ubuntu-latest\n    steps:\n    - name: 'Calculate PR commits + 1'\n      run: echo \"PR_FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))\" \u003e\u003e $GITHUB_ENV\n    - uses: actions/checkout@v3\n      with:\n        ref: ${{ github.event.pull_request.head.sha }}\n        fetch-depth: ${{ env.PR_FETCH_DEPTH }}\n    - name: Run DPDK checkpatches.sh review\n      uses: webispy/checkpatch-action@v9\n      env:\n        DPDK_CHECKPATCH_PATH: /usr/bin/checkpatch.pl\n        CHECKPATCH_COMMAND: ./devtools/checkpatches.sh\n```\n\n**Note:** For **private repositories** this action needs access to the `GITHUB_TOKEN`. It needs read access to `contents` and `pull-requests` as minimum permissions. For example:\n\n```yml\nname: checkpatch review\non: [pull_request]\njobs:\n  my_review:\n    name: checkpatch review\n    runs-on: ubuntu-latest\n    permissions:\n      contents: read\n      pull-requests: read\n    steps:\n    - name: 'Calculate PR commits + 1'\n      run: echo \"PR_FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))\" \u003e\u003e $GITHUB_ENV\n    - uses: actions/checkout@v3\n      with:\n        ref: ${{ github.event.pull_request.head.sha }}\n        fetch-depth: ${{ env.PR_FETCH_DEPTH }}\n    - name: Run checkpatch review\n      uses: webispy/checkpatch-action@v9\n      env:\n        GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}\n```\n\n### `checkpatch.pl` configuration\n\nThe `checkpatch.pl` tool supports a configuration file for setting options. Just create a `.checkpatch.conf` file in the top-level directory of your project and specify options in it.\n\n\u003chttps://docs.kernel.org/dev-tools/checkpatch.html#type-descriptions\u003e\n\n#### Example for `.checkpatch.conf` file\n\n```text\n# This isn't actually a Linux kernel tree\n--no-tree\n\n--ignore CONFIG_DESCRIPTION\n--ignore FILE_PATH_CHANGES\n--ignore GERRIT_CHANGE_ID\n--ignore GIT_COMMIT_ID\n--ignore NEW_TYPEDEFS\n--ignore SPDX_LICENSE_TAG\n--ignore SPACING\n--ignore CONST_STRUCT\n--ignore EMBEDDED_FUNCTION_NAME\n--exclude externals\n--exclude examples\n```\n\n## References\n\n### checkpatch tool\n\nFollowing files are used to this project.\n\n- \u003chttps://raw.githubusercontent.com/torvalds/linux/master/scripts/checkpatch.pl\u003e\n- \u003chttps://raw.githubusercontent.com/torvalds/linux/master/scripts/spelling.txt\u003e\n\n### Patch\n\n#### Add option for excluding directories\n\nFrom [zephyr](https://github.com/zephyrproject-rtos/zephyr) project:\n\n- \u003chttps://github.com/zephyrproject-rtos/zephyr/commit/92a12a19ae5ac5fdf441c690c48eed0052df326d\u003e\n\n#### Disable warning for \"No structs that should be const ...\"\n\n- \u003chttps://github.com/nugulinux/docker-devenv/blob/bionic/patches/0002-ignore_const_struct_warning.patch\u003e\n\n### Docker image\n\nYou can find the Dockerfile from [docker](https://github.com/webispy/checkpatch-action/tree/docker) branch of this repository.\n\n## License\n\nThe `checkpatch.pl` file is a script in the Linux kernel source tree, so **checkpatch-action** projects and forked projects must comply with the GPL-2.0 license (kernel license).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebispy%2Fcheckpatch-action","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwebispy%2Fcheckpatch-action","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebispy%2Fcheckpatch-action/lists"}