← 输入框|github.com|刷新
Skip to content

chore: group Dependabot updates and auto-merge safe ones - #92

Merged
nooogle merged 2 commits into
masterfrom
chore/dependabot-automation
Sep 16, 2026
Merged

nooogle merged 2 commits into
masterfrom
chore/dependabot-automation

Conversation

@nooogle

@nooogle nooogle commented Sep 16, 2026

Copy link
Copy Markdown
Owner

Applies the fleet-wide Dependabot automation agreed 2026-09-16. Same shape as CDS.ImageDisplay#39, which is merged.

Dependabot config

  • NuGet minor + patch grouped into one PR; security updates grouped separately (applies-to: security-updates). Majors stay ungrouped so they arrive individually for review.
  • github-actions moved from weekly to monthly, all in one group.
  • Dropped reviewers: (no longer in the Dependabot options reference); kept labels:/assignees:, which release_sweep.ps1 relies on for PR discovery and its label preflight.
  • No dotnet-sdk entry — it only acts on an sdk.version in global.json, which no repo here pins.

Auto-merge workflow

Enables auto-merge for third-party minor and patch bumps once the required check passes. Majors, and any inter-repo CDS.* bump, are labelled needs-review instead — release_sweep.ps1 merges those in dependency order, and landing one early can break a downstream repo's restore.

NuGet audit

NuGetAudit/NuGetAuditMode=all made explicit, with NU1903/NU1904 (high/critical) promoted to errors in CI only, so a newly published advisory never blocks local work.

Standards doc updated in dev-central (85f597b).

🤖 Generated with Claude Code

Groups NuGet minor/patch bumps into a single PR and security updates into
another, and moves github-actions updates to monthly in one group. Adds a
workflow that enables auto-merge for third-party minor and patch bumps once
the required check passes.

Majors and inter-repo CDS.* bumps are labelled needs-review rather than
merged: release_sweep.ps1 merges those in dependency order, and landing one
early can break a downstream repo's restore.

Already fully SHA-pinned, so no action changes here. Makes NU1903/NU1904 build
errors in CI only.
Co-Authored-By: Claude Opus 5 <noreply\@anthropic.com>
Copilot AI lite review requested due to automatic review settings September 16, 2026 13:35

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The critical workflow permission issue and moderate Dependabot grouping issue must be fixed before approval.

Get a fresh assessment by requesting another Copilot review.

Pull request overview

Configures Dependabot grouping, safe auto-merge automation, and CI-only NuGet vulnerability enforcement.

Changes:

  • Groups NuGet and GitHub Actions updates.
  • Adds Dependabot labeling and auto-merge logic.
  • Promotes high/critical NuGet advisories to CI errors.
File summaries
File Summary
Directory.Build.props Configures NuGet auditing and CI warning escalation.
.github/workflows/dependabot-automerge.yml Adds labeling and auto-merge logic. Critical: pull_request tokens are read-only, preventing write operations; use a privileged trigger.
.github/dependabot.yml Defines update schedules and groups. Moderate: Add applies-to: version-updates to prevent security updates entering the minor/patch group.
Review details

Suppressed comments (1)

.github/dependabot.yml:19

  • A group without applies-to matches both version and security updates, so a minor/patch security update can be consumed by nuget-minor-patch instead of the separate nuget-security group. Add applies-to: version-updates here to make the two groups mutually exclusive as described.
      nuget-minor-patch:
        patterns: [ "*" ]
        update-types: [ "minor", "patch" ]
  • Files reviewed: 3/3 changed files
  • Comments generated: 1
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@@ -0,0 +1,41 @@
name: Dependabot auto-merge

on: pull_request
gh pr edit --add-label writes issue labels, but this workflow's explicit
permissions block granted no issues scope at all, so the needs-review path
would have 403'd on the first major or inter-repo CDS.* bump -- silently
losing the routing that keeps release_sweep.ps1 in dependency order.

Grants issues: write and calls the labels endpoint through gh api directly,
which also avoids gh pr edit's projectCards query (cli/cli#6274, still open).

Found by Copilot review. The same review's pull_request_target recommendation
was declined: Dependabot-triggered pull_request runs have respected the
permissions key since 2021-10-11, and pull_request_target would be worse.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@nooogle
nooogle merged commit 8e1a5f0 into master Sep 16, 2026
8 checks passed
@nooogle
nooogle deleted the chore/dependabot-automation branch September 16, 2026 15:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants