Fix Windows stage: per-project restore (no root solution)#152
Merged
Conversation
The repo-template pr.yaml was synced back, reintroducing the bare dotnet restore at root that fails for this template pack. This template pack has no solution file at root. Discover the solution recursively or fall back to per-project restore/build. Blocks all PRs (#149, #150, #151). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the PR workflow’s Windows stage to restore/build correctly in a template-pack repository where dotnet restore at repo root fails due to no root solution.
Changes:
- Replaces bare root-level
dotnet restore/dotnet buildwith a PowerShell step that looks for a solution file and builds it when present. - Adds a fallback path to restore/build each project individually when no solution file is found.
- Remove -Depth 2 limit so solution discovery is truly recursive - Fail explicitly if no projects found (don't silently pass) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The pr.yaml from repo-template was synced back to this repo, reintroducing the bare
dotnet restoreat root that fails because this template pack has no solution file at root.This is the same root cause we hit before — the repo-template multi-stage workflow doesn't fit a template pack repo. The Stage 2 Windows job runs
dotnet restoreanddotnet buildfrom root with no solution/project specified.Fix
Replace bare commands with logic that:
This unblocks dependabot PRs #149, #150, and #151.
Note
This is a recurring issue. The repo-template workflow keeps getting synced here. Consider either:
dotnet restore src/instead of baredotnet restorein repo-template🤖 Generated with Claude Code