From fbce609c1d70874a9aa3d1b30506177395811fce Mon Sep 17 00:00:00 2001 From: Ankit Jain Date: Tue, 26 May 2026 19:07:58 -0400 Subject: [PATCH 01/15] refactor(cli): rename install-route identifiers to install-source MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Rename the C# identifiers, prose, file names, and xmldoc references that spoke of an "install route" to "install source" so the codebase matches the on-disk sidecar field name (`{"source":"..."}`) which has always been the authoritative spelling. Mechanical rename only. No behavior change. Wire strings are unchanged: `script`, `pr`, `winget`, `brew`, `dotnet-tool`, `localhive` all stay literal; the sidecar JSON field name was already `source`. Notable identifier renames: - `InstallSource.Brew` enum value → `InstallSource.Homebrew` (the wire string stays `"brew"` via the preserved `InstallSourceExtensions.BrewWire` constant — only the C# enum name and the friendlier display label change). - `InstallationInfo.Route` property → `InstallationInfo.Source` (and the associated `[JsonPropertyName("route")]` → `"source"`; this surface was added earlier in the branch and has not shipped). - `CliPathHelper.TryGetAspireHomeDirectoryFromInstallRoute` → `TryGetAspireHomeDirectoryFromInstallSource`. - `docs/specs/install-routes.md` → `docs/specs/install-sources.md`. - `tests/.../BundleServiceCrossRouteExtractionTests.cs` → `BundleServiceCrossSourceExtractionTests.cs` and the contained theory method's name. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- docs/dogfooding-pull-requests.md | 8 +-- eng/clipack/Common.projitems | 10 ++-- eng/scripts/get-aspire-cli-pr.ps1 | 22 +++---- eng/scripts/get-aspire-cli-pr.sh | 28 ++++----- eng/scripts/get-aspire-cli.ps1 | 8 +-- eng/scripts/get-aspire-cli.sh | 6 +- eng/scripts/verify-cli-archive.ps1 | 10 ++-- eng/scripts/verify-cli-tool-nupkg.ps1 | 2 +- localhive.ps1 | 14 ++--- localhive.sh | 6 +- .../Acquisition/IInstallSidecarReader.cs | 19 +++--- .../Acquisition/IInstallationDiscovery.cs | 10 ++-- .../Acquisition/IPeerInstallProbe.cs | 6 +- .../Acquisition/InstallSidecarReader.cs | 4 +- src/Aspire.Cli/Acquisition/InstallSource.cs | 14 ++--- .../InstallationCandidateSources.cs | 2 +- .../Acquisition/InstallationDiscovery.cs | 46 +++++++-------- .../Acquisition/InstallationInfo.cs | 16 ++--- .../Acquisition/WingetFirstRunProbe.cs | 4 +- src/Aspire.Cli/Commands/SetupCommand.cs | 8 +-- src/Aspire.Cli/Utils/CliPathHelper.cs | 4 +- .../Scripts/Common/FakeArchiveHelper.cs | 4 +- .../Scripts/LocalHiveScriptFunctionTests.cs | 12 +++- .../Scripts/PRScriptInstallE2ETests.cs | 4 +- .../Scripts/PRScriptInstallerModeTests.cs | 10 ++-- .../Scripts/PRScriptPowerShellTests.cs | 36 ++++++------ .../Scripts/PRScriptShellTests.cs | 40 ++++++------- .../Scripts/PRScriptToolModeTests.cs | 12 ++-- .../Scripts/ReleaseScriptPowerShellTests.cs | 12 ++-- .../Scripts/ReleaseScriptShellTests.cs | 12 ++-- .../VerifyCliArchivePowerShellTests.cs | 6 +- .../Acquisition/InstallSidecarReaderTests.cs | 12 ++-- .../InstallationDiscoveryDiscoverAllTests.cs | 58 +++++++++---------- ...dleServiceComputeDefaultExtractDirTests.cs | 12 ++-- ...undleServiceCrossSourceExtractionTests.cs} | 12 ++-- .../Utils/CliPathHelperTests.cs | 16 ++--- 36 files changed, 257 insertions(+), 248 deletions(-) rename tests/Aspire.Cli.Tests/Bundles/{BundleServiceCrossRouteExtractionTests.cs => BundleServiceCrossSourceExtractionTests.cs} (93%) diff --git a/docs/dogfooding-pull-requests.md b/docs/dogfooding-pull-requests.md index dafd90fe7d1..12cf09188fd 100644 --- a/docs/dogfooding-pull-requests.md +++ b/docs/dogfooding-pull-requests.md @@ -329,9 +329,9 @@ The file is scoped to the solution directory and only affects projects under it. The Homebrew cask (`eng/homebrew/aspire.rb.template`) installs Aspire entirely inside the Caskroom version directory — `brew uninstall aspire` removes -the binary and the route sidecar end-to-end. The cask intentionally carries -no `zap` stanza, because `~/.aspire/` is a shared prefix with the script-route -and PR-route installers and a brew-driven recursive delete would clobber state +the binary and the source sidecar end-to-end. The cask intentionally carries +no `zap` stanza, because `~/.aspire/` is a shared prefix with the script-source +and PR-source installers and a brew-driven recursive delete would clobber state those installers still own. If you installed via the Homebrew cask before this change, you may have a @@ -343,7 +343,7 @@ Clean it up manually once after upgrading the cask: rm -rf ~/.aspire/installs/brew-stable ``` -NuGet hives under `~/.aspire/hives/` and any script-route or PR-route +NuGet hives under `~/.aspire/hives/` and any script-source or PR-source binaries under `~/.aspire/bin/` and `~/.aspire/dogfood/` are not touched by the cask in either direction; manage those with the steps above. diff --git a/eng/clipack/Common.projitems b/eng/clipack/Common.projitems index d9bfc4e9dab..049c8403def 100644 --- a/eng/clipack/Common.projitems +++ b/eng/clipack/Common.projitems @@ -42,12 +42,12 @@