From 30ede1d1659c69bfaf6bdab0675441061c10ab30 Mon Sep 17 00:00:00 2001 From: BornToBeRoot <16019165+BornToBeRoot@users.noreply.github.com> Date: Fri, 30 Oct 2026 00:40:17 +0100 Subject: [PATCH] CI: AppVeyor: Branch builds only for main and release tags skip_branch_with_pr only works for pushes after the PR exists. The first push of a branch (e.g. Dependabot pushes and opens the PR within seconds, #3678 / #3681) is still built as branch build, which blocks the single AppVeyor job for nothing. Other branches are only built as PR now; the branch filter also applies to tag names, so release tags are included via a pattern. Co-Authored-By: Claude Opus 5.5 --- AGENTS.md | 2 +- appveyor.yml | 9 +++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 8cd0de9c93..ba35377b67 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -189,7 +189,7 @@ The website is deployed to GitHub Pages at: https://borntoberoot.net/NETworkMana architecture, only for tags). PRs only build the application (`NETworkManager.csproj`) unless they change `Source/NETworkManager.Setup/`, branches and tags the setup (`NETworkManager.Setup.wixproj`) - Runs the unit tests (`Source/NETworkManager.Tests`, `dotnet test --project`) -- Branches with an open PR are only built as PR (`skip_branch_with_pr`) +- Branch builds only for `main` and release tags (`branches: only`), other branches are only built as PR - Ends successfully without building if only docs / website / repository files changed (`Website/`, `.github/`, `.claude/`, `Images/`, `Chocolatey/`, `WinGet/`, `Tests/Environments/`, `*.md`, `LICENSE`), so Mergify still gets a green status. Tags are always built. Branch builds (e.g. `main`) only see the last commit, so they are only skipped diff --git a/appveyor.yml b/appveyor.yml index f76bb5cb0b..632aeb7bb3 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -9,8 +9,13 @@ environment: # Shallow clone - the history isn't needed (the version is date based). Must stay > 1, the docs-only check below # compares HEAD with HEAD~1. clone_depth: 50 -# Branches with an open PR are built as PR (merge commit) only - Mergify waits for that status. -skip_branch_with_pr: true +# Branch builds only for main and release tags (e.g. 2026.10.24.0 - the filter also applies to tag names). Other +# branches are only built as PR (merge commit), Mergify waits for that status. skip_branch_with_pr is not enough, the +# first push of a branch (e.g. by Dependabot) is built before the PR exists. PRs to main are not affected by "only". +branches: + only: + - main + - /^\d+\.\d+\.\d+/ install: - ps: | # Skip the build if only docs / website / repository files changed. Exit-AppveyorBuild ends the build