chore(rebrand): rename NukeBuild → FalloutBuild + INukeBuild → IFalloutBuild#59
Merged
Merged
Conversation
…utBuild Mechanical type-identifier rename deferred from #54. ## What changed - 7 files renamed (git mv preserves history): - src/Fallout.Build/NukeBuild.{,Events,Interface,Statics,Output}.cs → FalloutBuild.{,Events,Interface,Statics,Output}.cs - src/Fallout.Build/INukeBuild.cs → IFalloutBuild.cs - src/Fallout.SourceGenerators/Shims/NukeBuild.cs → FalloutBuild.cs - ~281 identifier occurrences across 84 files swapped via anchored regex (\bNukeBuild\b, \bINukeBuild\b) - Verify snapshots (cake-scripts/*.verified.cs, SchemaUtilityTest verified.json) updated to match the new generator output - build/Build.cs (this repo's own build script) updated alongside ## Carve-outs preserved - CHANGELOG.md — historical entries reference the old types verbatim - .fallout/build.schema.json — regenerated by the build, not hand-edited ## Out of scope (follow-up PRs) While auditing, I found more identifiers carrying the legacy Nuke brand than the issue body anticipated: - Constants.cs internals: NukeFileName, NukeDirectoryName, NukeCommonPackageId, GetNukeDirectory, GlobalNukeDirectory - MSBuild target / property names (consumer-visible, BREAKING): NukeTasksAssembly, NukeContinueOnError, NukeTaskTimeout, NukeBaseDirectory, NukeUseNestedNamespaces, NukeRepositoryUrl, NukeUpdateReferences, NukeExternalFiles, NukePackPackageTools, NukeEmbedPackagesForSelfContained, NukeCodeGeneration, NukeSpecificationFiles, NukeBaseNamespace, NukeTasksDirectory, NukeTasksEnabled, NukeDefaultExcludes, NukeRootDirectory, NukeScriptDirectory, NukeTelemetryVersion - Env vars (NUKE_TELEMETRY_OPTOUT, NUKE_GLOBAL_TOOL_*, NUKE_INTERNAL_INTERCEPTOR) - Credential store name prefix "NUKE: ..." - Telemetry property keys version_nuke_common, version_nuke_global_tool The MSBuild props are consumer-visible and need their own deprecation discussion (set both old + new for a release? Read both with warning?). Env vars + credential store need migration logic. Splitting these out keeps the diff reviewable and lets each concern get its own design call. #57 updated to reflect the expanded scope. ## Verification - dotnet build fallout.slnx -c Debug: 0 errors, 15 pre-existing warnings - dotnet test fallout.slnx: 391 passed, 7 skipped, 0 failed Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
14 tasks
ChrisonSimtian
added a commit
that referenced
this pull request
May 21, 2026
Closes part of #48 (MVP — see "What's NOT in this PR" below). ## What it does A new `dotnet tool` that walks a consumer repo and rewrites the NUKE-era artifacts into their Fallout equivalents in place: dotnet tool install -g Fallout.Migrate cd path/to/my-nuke-repo fallout-migrate # apply fallout-migrate --dry-run # preview without writing Transformations: | Layer | Rewriter | What changes | |---|---|---| | `.csproj` | CsprojRewriter | PackageReference Include="Nuke.X" → Fallout.X; MSBuild props on the known P3.5b list (NukeRootDirectory, NukeBaseDirectory, NukeTelemetryVersion, NukeTasksEnabled, …) → Fallout* | | `.cs` | CodeRewriter | `\bNuke\.(?=[A-Z])` → `Fallout.` for using directives, attribute namespaces, qualified type references; `\bNukeBuild\b` → `FalloutBuild`; `\bINukeBuild\b` → `IFalloutBuild` | | `build.{cmd,ps1,sh}` | ScriptRewriter | `dotnet nuke` → `dotnet fallout`; `.nuke/` path references → `.fallout/`; legacy NUKE_* env vars → FALLOUT_* | | `.nuke/` dir | DirectoryRenamer | Renames to `.fallout/` (warning emitted if both exist) | Each rewriter uses anchored regex matching the same approach the rebrand itself used in #54 / #59 (`\bNuke\.` with case-aware lookaheads). Internal regex-only — no Roslyn dependency, no MSBuild evaluation, keeps the tool a single small binary. ## Output fallout-migrate — migrating: /path/to/repo edit build/_build.csproj (3 changes) edit build/Build.cs (2 changes) edit build.sh (2 changes) rename .nuke -> .fallout Files changed: 3 Edits made: 7 Directories: 1 renamed Migration complete. Verify the build: ./build.ps1 (or ./build.sh on unix) ## Tests 17 tests: - CsprojRewriterTest: PackageReference, MSBuild property, false-positive guard, no-op - CodeRewriterTest: using directive, qualified type, NukeBuild, INukeBuild, partial-identifier guard, lowercase .nuke guard - ScriptRewriterTest: dotnet nuke, .nuke dir refs, env vars, plain-word guard - MigrationIntegrationTest: end-to-end vanilla fixture (csproj+cs+sh+.nuke), dry-run, both-dirs warning Plus a manual end-to-end smoke from a fixture in /tmp confirmed dry-run output matches the expected diff. ## What's NOT in this PR (deferred) - Roslyn-based AST rewrites — kept it regex-only for MVP. The issue mentions reusing the Cake rewriting infrastructure; that's more appropriate when we hit cases regex can't handle (e.g. partial identifier disambiguation, semantic-aware refactors). None observed in vanilla consumer repos yet. - Tested on a real external NUKE consumer repo — volunteer needed per the issue's "Done when" list. Open follow-up. - Published to GitHub Packages — release pipeline will pick this up on next push to main since the project is in fallout.slnx and PackAsTool=true. - Link from migration guide (#37) — that PR doesn't exist yet. ## Side-effect StronglyTypedSolutionGeneratorTest verify snapshot regenerated — solution generator now emits Solution.Fallout_Migrate and Solution.Fallout_Migrate_Tests properties from the two new projects. ## Verification - dotnet build src/Fallout.Migrate: 0 errors, 0 warnings - dotnet test fallout.slnx: 408 passed (was 391; +17 new), 7 skipped, 0 failed - End-to-end dry-run on /tmp fixture: edits + rename reported correctly Co-authored-by: Claude Opus 4.7 (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
Mechanical type-identifier rename deferred from #54. Touches only the
NukeBuild/INukeBuildtypes and their containing files — leaves the other identifier families (MSBuild props, env vars, credential store, internal constants) for follow-up PRs with their own deprecation analysis.Refs #57.
What changed
git mv, history follows):src/Fallout.Build/NukeBuild.{,Events,Interface,Statics,Output}.cs→FalloutBuild.{,Events,Interface,Statics,Output}.cssrc/Fallout.Build/INukeBuild.cs→IFalloutBuild.cssrc/Fallout.SourceGenerators/Shims/NukeBuild.cs→FalloutBuild.cs\bNukeBuild\b,\bINukeBuild\b)cake-scripts/*.verified.cs,SchemaUtilityTest *.verified.json) updated to match the new generator outputbuild/Build.csupdated alongsideCarve-outs preserved
CHANGELOG.md— historical entries reference the old types verbatim.fallout/build.schema.json— regenerated by the build, not hand-editedOut of scope (will be follow-up PRs)
While auditing, I found significantly more identifiers carrying the legacy Nuke brand than the issue body anticipated. Each needs its own discussion:
NukeFileName,NukeDirectoryName,NukeCommonPackageId,GetNukeDirectory,GlobalNukeDirectory)NukeTasksAssembly,NukeContinueOnError,NukeBaseDirectory, ~19 others in.targets/.csproj).csprojfiles.NUKE_TELEMETRY_OPTOUT,NUKE_GLOBAL_TOOL_*,NUKE_INTERNAL_INTERCEPTOR)"NUKE: ...")version_nuke_common,version_nuke_global_tool)#57 will be updated to reflect the expanded scope.
Verification
dotnet build fallout.slnx -c Debug: 0 errors, 15 pre-existing warningsdotnet test fallout.slnx: 391 passed, 7 skipped, 0 failedTest plan
ubuntu-latestCI green on this PRmain's release run (release won't republish — same version)🤖 Generated with Claude Code