{"id":30535418,"url":"https://github.com/dabao1955/kernel_build_action","last_synced_at":"2025-08-27T14:55:20.000Z","repository":{"id":199110180,"uuid":"702134322","full_name":"dabao1955/kernel_build_action","owner":"dabao1955","description":"a action to build kernel automatically[force push warning!]","archived":false,"fork":false,"pushed_at":"2025-07-27T12:30:11.000Z","size":3519,"stargazers_count":112,"open_issues_count":4,"forks_count":165,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-07-27T14:41:01.530Z","etag":null,"topics":["action","actions","android","aosp-android","builder","ci","kernel","kernelsu"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dabao1955.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-10-08T15:42:39.000Z","updated_at":"2025-07-24T09:13:34.000Z","dependencies_parsed_at":"2023-10-15T00:17:09.257Z","dependency_job_id":"d6e2c094-3c5b-4cf3-b324-410faa4487b9","html_url":"https://github.com/dabao1955/kernel_build_action","commit_stats":null,"previous_names":["dabao1955/kernel_build_action"],"tags_count":35,"template":false,"template_full_name":null,"purl":"pkg:github/dabao1955/kernel_build_action","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dabao1955%2Fkernel_build_action","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dabao1955%2Fkernel_build_action/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dabao1955%2Fkernel_build_action/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dabao1955%2Fkernel_build_action/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dabao1955","download_url":"https://codeload.github.com/dabao1955/kernel_build_action/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dabao1955%2Fkernel_build_action/sbom","scorecard":{"id":316228,"data":{"date":"2025-08-11","repo":{"name":"github.com/dabao1955/kernel_build_action","commit":"5a7e8f2041abe5bfa4b7285cde3ebda1e4ac4a2f"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":6.7,"checks":[{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":0,"reason":"Found 1/28 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":10,"reason":"30 commit(s) and 6 issue activity found in the last 90 days -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Security-Policy","score":10,"reason":"security policy file detected","details":["Info: security policy file detected: SECURITY.md:1","Info: Found linked content: SECURITY.md:1","Info: Found disclosure, vulnerability, and/or timelines in security policy: SECURITY.md:1","Info: Found text in security policy: SECURITY.md:1"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Token-Permissions","score":7,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Info: jobLevel 'contents' permission set to 'read': .github/workflows/build.yml:12","Info: jobLevel 'contents' permission set to 'read': .github/workflows/check.yml:16","Info: jobLevel 'contents' permission set to 'read': .github/workflows/check.yml:55","Warn: jobLevel 'contents' permission set to 'write': .github/workflows/close-pr.yml:13","Info: jobLevel 'contents' permission set to 'read': .github/workflows/lkm.yml:15","Info: jobLevel 'contents' permission set to 'read': .github/workflows/lkm.yml:28","Warn: jobLevel 'contents' permission set to 'write': .github/workflows/main.yml:19","Warn: no topLevel permission defined: .github/workflows/build.yml:1","Warn: no topLevel permission defined: .github/workflows/check.yml:1","Warn: no topLevel permission defined: .github/workflows/close-pr.yml:1","Warn: no topLevel permission defined: .github/workflows/lkm.yml:1","Warn: no topLevel permission defined: .github/workflows/main.yml:1"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: third-party GitHubAction not pinned by hash: .github/workflows/build.yml:16: update your workflow using https://app.stepsecurity.io/secureworkflow/dabao1955/kernel_build_action/build.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/check.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/dabao1955/kernel_build_action/check.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/check.yml:62: update your workflow using https://app.stepsecurity.io/secureworkflow/dabao1955/kernel_build_action/check.yml/main?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/check.yml:65: update your workflow using https://app.stepsecurity.io/secureworkflow/dabao1955/kernel_build_action/check.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/close-pr.yml:19: update your workflow using https://app.stepsecurity.io/secureworkflow/dabao1955/kernel_build_action/close-pr.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/close-pr.yml:39: update your workflow using https://app.stepsecurity.io/secureworkflow/dabao1955/kernel_build_action/close-pr.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/lkm.yml:19: update your workflow using https://app.stepsecurity.io/secureworkflow/dabao1955/kernel_build_action/lkm.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/lkm.yml:32: update your workflow using https://app.stepsecurity.io/secureworkflow/dabao1955/kernel_build_action/lkm.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/main.yml:23: update your workflow using https://app.stepsecurity.io/secureworkflow/dabao1955/kernel_build_action/main.yml/main?enable=pin","Warn: npmCommand not pinned by hash: .github/workflows/check.yml:38","Info:   0 out of   7 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   2 third-party GitHubAction dependencies pinned","Info:   0 out of   1 npmCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: Apache License 2.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":6,"reason":"branch protection is not maximal on development and all release branches","details":["Info: 'allow deletion' disabled on branch 'main'","Info: 'force pushes' disabled on branch 'main'","Warn: 'branch protection settings apply to administrators' is disabled on branch 'main'","Info: 'stale review dismissal' is required to merge on branch 'main'","Warn: required approving review count is 1 on branch 'main'","Warn: codeowners review is required - but no codeowners file found in repo","Info: 'last push approval' is required to merge on branch 'main'","Warn: no status checks found to merge onto branch 'main'","Info: PRs are required in order to make changes on branch 'main'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":8,"reason":"SAST tool is not run on all commits -- score normalized to 8","details":["Warn: 4 commits out of 5 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-18T00:14:15.906Z","repository_id":199110180,"created_at":"2025-08-18T00:14:15.906Z","updated_at":"2025-08-18T00:14:15.906Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272341693,"owners_count":24917505,"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-08-27T02:00:09.397Z","response_time":76,"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","actions","android","aosp-android","builder","ci","kernel","kernelsu"],"created_at":"2025-08-27T14:55:06.276Z","updated_at":"2025-08-27T14:55:19.921Z","avatar_url":"https://github.com/dabao1955.png","language":"Python","funding_links":[],"categories":["🛠️ Building from Source","android"],"sub_categories":["Building Tools \u0026 Scripts"],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003ch1\u003eAndroid Kernel Build Action\u003c/h1\u003e\n  \u003ch3\u003e\u003ci\u003ePowered By GitHub Actions\u003c/i\u003e\u003c/h3\u003e\n\u003c/div\u003e\n\nA workflow to automatically build an Android kernel\n\n[![](https://img.shields.io/github/actions/workflow/status/dabao1955/kernel_build_action/main.yml?style=for-the-badge\u0026color=fee4d0\u0026logo=githubactions\u0026logoColor=fee4d0)](https://github.com/dabao1955/kernel_build_action/actions/workflows/main.yml)\n[![](https://img.shields.io/github/issues/dabao1955/kernel_build_action?style=for-the-badge\u0026color=fee4d0\u0026logo=files\u0026logoColor=fee4d0)](https://github.com/dabao1955/kernel_build_action/issues)\n[![](https://img.shields.io/github/stars/dabao1955/kernel_build_action?style=for-the-badge\u0026color=fee4d0\u0026logo=starship\u0026logoColor=fee4d0)](https://github.com/dabao1955/kernel_build_action/stargazers)\n[![](https://img.shields.io/github/forks/dabao1955/kernel_build_action?style=for-the-badge\u0026color=fee4d0\u0026logo=git\u0026logoColor=fee4d0)](https://github.com/dabao1955/kernel_build_action/forks)\n[![](https://img.shields.io/github/license/dabao1955/kernel_build_action?style=for-the-badge\u0026color=fee4d0\u0026logo=apache\u0026logoColor=fee4d0)](https://github.com/dabao1955/kernel_build_action/blob/main/LICENSE)\n[![](https://img.shields.io/github/v/release/dabao1955/kernel_build_action?style=for-the-badge\u0026color=fee4d0\u0026logo=github\u0026logoColor=fee4d0)](https://github.com/dabao1955/kernel_build_action/releases/latest)\n[![](https://img.shields.io/github/last-commit/dabao1955/kernel_build_action?style=for-the-badge\u0026color=fee4d0\u0026logo=codeigniter\u0026logoColor=fee4d0)](https://github.com/dabao1955/kernel_build_action/commits/main/)\n\n\n\n\u003e [!IMPORTANT]\n\u003e This workflow is universal. You need to have a certain understanding in writing github workflows and a little knowledge of the Android kernel to use this.\n\n## Security Policy\nSee [Security.md](./SECURITY.md) for more details.\n\n\n## How to use?\n- First, you need to determine the kernel source code and configuration files.\n- Find your kernel source repository and configure the workflow file according to the following example and README.md:\n\n```yml\nname: CI\n\non:\n  workflow_dispatch:\n\njobs:\n  build-kernel:\n    name: Build Kernel\n    runs-on: ubuntu-22.04\n    steps:\n      - name: Build\n        uses: dabao1955/kernel_build_action@main\n        with:\n          kernel-url: https://github.com/AcmeUI-Devices/android_kernel_xiaomi_cas\n          kernel-branch: taffy\n          config: cas_defconfig\n          arch: arm64\n          aosp-gcc: true\n          aosp-clang: true\n          android-version: 12\n          aosp-clang-version: r383902\n```\nOr use the [preset workflow file](https://github.com/dabao1955/kernel_build_action/blob/main/.github/workflows/build.yml) to modify it.\n\n\u003e [!NOTE]\n\u003e You do not need to fork this repository.\n\u003e\n\u003e If you just want to compile the kernel, please do not submit PR after modification!\n\n- Finally, run the workflow you just wrote.\n## Inputs\n\u003e [!WARNING]\n\u003e\n\u003e enable lxc or nethunter input options may cause kernel compilation failed!\n\n| input               | required | description | example value |\n|---------------------|----------|-------------|---------|\n| kernel-url | true | URL of Android kernel source code for your phone | https://github.com/username/project |\n| kernel-dir | false | The directory name of the Android kernel source code. This option may be used for OPLUS Kernel source code. | kernel |\n| depth | false | | 1 |\n| vendor | false | | false |\n| vendor-url | false | url of additional source code for the Android kernel source code. This option may be used for OPLUS source code. | https://github.com/username/project|\n| vendor-dir | false | | vendor |\n| kernel-branch | false | The branch of the source code that needs to be cloned, defaults branch to git clone is main | main |\n| vendor-branch | false | The branch of the vendor source code that needs to be cloned, defaults branch to git clone is main | main |\n| config | true | Compile the selected configuration file for the Android kernel | defconfig |\n| arch | true | The architecture of your mobile phone SOC is arm64 by default | arm64 |\n| android-version | true | The Android version required when downloading aosp-clang. If you want to use the latest aosp-clang or you do not use aosp-clang to compile the kernel, please ignore this option | 12 |\n| ksu | false | Enable KernelSU | true |\n| ksu-version | false | KernelSU version | v0.9.5 |\n| ksu-lkm(may not build successfully for non-GKI devices) | false | Build KernelSU as a linux kernel module | true |\n| ksu-other | false | | false |\n| ksu-url | false | Use 3rd KernelSU | https://github.com/xxx/KernelSU/ |\n| rekernel | false | Enable Re-Kernel support | true |\n| disable-lto | false | Disable [Link Time Optimization](https://llvm.org/docs/LinkTimeOptimization.html) | false |\n| lxc | false | Enable LXC and docker to config | false | \n| lxc-patch | false | Add patch avoid not booting after enable lxc | false | \n| nethunter | false | Enable Kali nethunter | false | \n| nethunter-patch | false | | false |\n| kvm | false | | false |\n| ccache | false | Enable ccache(Only valid when compiled with clang) | false |\n| aosp-gcc | false | Use aosp-gcc to compile the kernel or assist in compiling the kernel (when aosp-clang is enabled) | false |\n| other-gcc32-url | false | Please fill in the download link of other gcc32 in this option. Supports .xz, .zip, .tar and .git formats | https://github.com/username/gcc |\n| other-gcc32-branch | false | | main |\n| other-gcc64-url | false | Please fill in the download link of other gcc64 in this option. Supports .xz, .zip, .tar and .git formats | https://github.com/username/gcc |\n| other-gcc64-branch | false | | main |\n| aosp-clang | false | Compile the kernel using aosp-clang | false |\n| aosp-clang-version | false | please search for them according to your own needs at [official website](https://android.googlesource.com/platform/prebuilts/clang/host/linux-x86) and choose the appropriate clang according to the Android system version instead of blindly choosing `r383902` | r383902 |\n| other-clang-url | false | Please fill in the download link of other clang in this option. Supports .xz, .zip, .tar and .git formats | https://github.com/kdrag0n/proton-clang |\n| other-clang-branch | false | | 10.0|\n| anykernel3 | false | Package the compiled kernel using AnyKernel3. If this option is disabled, You need to fill `bootimg-url`. | false |\n| anykernel3-url | false | 3rdparty AnyKernel3 url | https://github.com/username/AnyKernel3 |\n| release | false | After the kernel compilation is completed, it will be automatically published to the releases page | true |\n| access-token | false | Please fill it if you want to release kernel | ghp_xxxxxx |\n| bootimg-url | false | A URL that can download the local boot.img | https://127.0.0.1/boot.img |\n| extra-cmd | false | Compile the kernel with extra options, such as LD=ld.lld | AS=llvm-as |\n\n## FAQ\n\u003e [!CAUTION]\n\u003e Please Read this first if you have some questions!\n\n### How to use 3rd clang？\nYou should disable aosp-clang and android-ndk options to use it.\n\n### Why KernelSU version built with this action is still v0.9.5？\nSee [KernelSU 's release note](https://github.com/tiann/KernelSU/releases/tag/v1.0.0) for more details.\n\n### How to submit issue about features requests?\nIn principle, it only accepts Bug Reports and does not accept external Feature Requests; if you want new features, you are welcome to submit a Pull Request. We will still develop new features that we think are useful.\n\n### Why the workflow exits with a code with an error value of some number？\n- If you get an error while downloading the toolchain or pulling the source code, please check whether your option or source code address is legitimate.\n- If you encounter problems during compilation, consider replacing the source code or replacing the compiler.\n- If the action has a typo problem, PR welcome!\n\n### Build failed while using third-party GCC ?\nTry add LLVM=1 option with clang.\n\n## Credits\n- [KernelSU](https://github.com/tiann/KernelSU)\n- [KernelSU_Action](https://github.com/XiaoleGun/KernelSU_Action)\n- [slimhub_actions](https://github.com/rokibhasansagar/slimhub_actions)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdabao1955%2Fkernel_build_action","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdabao1955%2Fkernel_build_action","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdabao1955%2Fkernel_build_action/lists"}