chore: update GitHub actions workflow for cppcheck - #367
Conversation
1. Updated actions/checkout from v4 to v7 for better stability and features 2. Added allow-unsafe-pr-checkout: true parameter to permit checkouts from unsafe PRs 3. Maintained existing functionality while improving security and compatibility Influence: 1. Verify cppcheck workflow still runs successfully on PR submissions 2. Test with different PR scenarios including unsafe origins 3. Confirm persisted credentials handling remains disabled chore: 更新GitHub actions的cppcheck工作流程 1. 将actions/checkout从v4升级到v7以获得更好的稳定性和功能 2. 添加allow-unsafe-pr-checkout: true参数以允许从不安全的PR检出 3. 在改进安全性和兼容性的同时保持原有功能 Influence: 1. 验证cppcheck工作流程在PR提交时仍能成功运行 2. 测试包括不安全源在内的不同PR场景 3. 确认持久化凭据处理保持禁用状态
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: Johnson-zs The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Reviewer's guide (collapsed on small PRs)Reviewer's GuideThis PR updates the cppcheck GitHub Actions workflow to use a newer version of actions/checkout and configures it to explicitly allow unsafe PR checkouts while keeping credentials persistence disabled. Flow diagram for updated cppcheck GitHub Actions workflowflowchart TD
A[cppcheck workflow trigger on pull_request] --> B[Step run: export]
B --> C[Step actions_checkout_v7]
C --> D[Step action_cppcheck]
subgraph Checkout_configuration
C1[ref = github.event.pull_request.head.sha]
C2[persist-credentials = false]
C3[allow-unsafe-pr-checkout = true]
end
C --> C1
C --> C2
C --> C3
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
deepin pr auto review★ 总体评分:100分■ 【总体评价】
■ 【详细分析】
■ 【改进建议代码示例】 # 当前代码已经是最佳实践,无需进一步修改
jobs:
cppcheck:
runs-on: ubuntu-latest
steps:
- run: export
- uses: actions/checkout@v7
with:
ref: ${{ github.event.pull_request.head.sha }}
persist-credentials: false
allow-unsafe-pr-checkout: true
- uses: linuxdeepin/action-cppcheck@main
with:
github_token: ${{ secrets.GITHUB_TOKEN }} |
|
/forcemerge |
|
This pr force merged! (status: blocked) |
features
from unsafe PRs
compatibility
Influence:
chore: 更新GitHub actions的cppcheck工作流程
Influence:
Summary by Sourcery
Update the cppcheck GitHub Actions workflow to use the latest checkout action and support unsafe PR checkouts while keeping credentials non-persistent.
CI: