Skip to content

Instantly share code, notes, and snippets.

@guibranco
Last active April 21, 2026 16:56
Show Gist options
  • Select an option

  • Save guibranco/648159133ec0ffb28191b3bb8ede4cde to your computer and use it in GitHub Desktop.

Select an option

Save guibranco/648159133ec0ffb28191b3bb8ede4cde to your computer and use it in GitHub Desktop.
Dependabot template for .NET projects with grouped NuGet updates and GitHub Actions support
version: 2
updates:
#
# NuGet dependencies
#
- package-ecosystem: "nuget"
directory: "/"
schedule:
interval: weekly
open-pull-requests-limit: 10
assignees:
- "guibranco"
reviewers:
- "guibranco"
labels:
- "nuget"
- "packages"
- ".NET"
- "dependencies"
groups:
#
# Microsoft packages
#
microsoft:
patterns:
- "Microsoft.*"
#
# ASP.NET Core stack
#
aspnetcore:
patterns:
- "Microsoft.AspNetCore.*"
#
# Extensions ecosystem
#
extensions:
patterns:
- "Microsoft.Extensions.*"
#
# Test stack
#
testing:
patterns:
- "xunit*"
- "FluentAssertions*"
- "Moq*"
- "coverlet*"
- "Microsoft.NET.Test.Sdk"
#
# Logging stack
#
logging:
patterns:
- "Serilog*"
- "NLog*"
#
# OpenTelemetry
#
telemetry:
patterns:
- "OpenTelemetry*"
#
# Azure SDK
#
azure:
patterns:
- "Azure.*"
#
# Everything else
#
dependencies:
patterns:
- "*"
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: weekly
open-pull-requests-limit: 5
assignees:
- "guibranco"
reviewers:
- "guibranco"
labels:
- "github-actions"
- "dependencies"
groups:
github-actions:
patterns:
- "*"
@guibranco
Copy link
Copy Markdown
Author

Dependabot configuration template for modern .NET / C# repositories.

This setup reduces pull request noise by grouping related NuGet dependencies into logical update batches (Microsoft.*, ASP.NET Core, Extensions, Testing, Logging, Azure, etc.) instead of opening dozens of individual PRs.

It also includes GitHub Actions updates and sensible defaults for reviewers, labels, scheduling, and PR limits.

Useful for:

  • .NET libraries
  • ASP.NET Core APIs
  • console tools
  • GitHub Actions written in .NET
  • automation repositories
  • mono-repos with shared SDK dependencies

Highlights:

  • Groups Microsoft dependency families together
  • Bundles testing framework updates
  • Bundles logging stack updates
  • Bundles telemetry stack updates
  • Supports Azure SDK updates
  • Includes fallback catch-all dependency grouping
  • Reduces CI failures caused by partial upgrades
  • Keeps GitHub Actions dependencies up to date
  • Prevents Dependabot PR spam

Designed as a reusable baseline template for production-grade repositories.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment