deps: Update dependency dotnet-sdk to v10.0.302 #22
Workflow file for this run
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
| # Auto-merge — enables GitHub native auto-merge (squash) via GITHUB_TOKEN. | |
| # | |
| # Synced from github-settings-automation/templates/auto-merge.yml by the | |
| # weekly enforce-repo-settings sweep. Do not hand-edit per-repo. | |
| # | |
| # Event-driven and per-repo: enables native auto-merge only for trusted | |
| # automation branches (prefix policy below). Renovate PRs don't need this | |
| # workflow — the shared preset (github>ANcpLua/github-settings-automation) | |
| # sets `platformAutomerge: true`. | |
| # | |
| # Prereqs (one-time per repo): "Allow auto-merge" enabled in repo settings, | |
| # and branch protection on `main` listing the required status checks native | |
| # auto-merge waits for. enforce-repo-settings.yml flips allow_auto_merge | |
| # automatically across the fleet. | |
| # | |
| # delete-merged-branch: repo-level delete_branch_on_merge reliably fires for | |
| # user-initiated merges but not for merges landed by the github-actions app | |
| # via native auto-merge (observed fleet-wide, e.g. qyl #452–#456, #477–#479 | |
| # survived; user-merged #476 was deleted). This job closes that gap for the | |
| # automation prefixes. HEAD_REF is passed via env, never interpolated into | |
| # the script, so a crafted branch name cannot inject into the shell under | |
| # pull_request_target's write token. | |
| # | |
| # Branch-prefix policy: | |
| # - claude/ — Claude Code agents | |
| # | |
| # Both jobs require head.repo.full_name == github.repository. A branch prefix | |
| # is chosen by whoever opens the PR, and pull_request_target runs with the base | |
| # repo's write token even for fork PRs — so the prefix alone gates nothing. | |
| # Without the same-repo check, any fork can push a `claude/…` branch and land | |
| # it on main unreviewed. | |
| name: Auto-merge | |
| on: | |
| pull_request_target: | |
| types: [opened, synchronize, reopened, ready_for_review, closed] | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| jobs: | |
| enable-auto-merge: | |
| runs-on: ubuntu-latest | |
| if: | | |
| github.event.action != 'closed' && | |
| github.event.pull_request.draft == false && | |
| github.event.pull_request.head.repo.full_name == github.repository && | |
| startsWith(github.event.pull_request.head.ref, 'claude/') | |
| steps: | |
| - name: Enable native auto-merge (squash) | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: gh pr merge ${{ github.event.pull_request.number }} --auto --squash --repo ${{ github.repository }} | |
| delete-merged-branch: | |
| runs-on: ubuntu-latest | |
| if: | | |
| github.event.action == 'closed' && | |
| github.event.pull_request.merged == true && | |
| github.event.pull_request.head.repo.full_name == github.repository && | |
| startsWith(github.event.pull_request.head.ref, 'claude/') | |
| steps: | |
| - name: Delete merged head branch | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| HEAD_REF: ${{ github.event.pull_request.head.ref }} | |
| run: | | |
| gh api -X DELETE "repos/${{ github.repository }}/git/refs/heads/$HEAD_REF" \ | |
| || echo "head branch already deleted" |