Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

fix(web): recognize existing Cap CLI shim with alternate path

Richie McIlroy21d275e550c0
diff --git a/apps/web/app/install-cli.ps1/route.ts b/apps/web/app/install-cli.ps1/route.ts
index 8ffdd954a..563d80974 100644
--- a/apps/web/app/install-cli.ps1/route.ts
+++ b/apps/web/app/install-cli.ps1/route.ts
@@ -45,7 +45,7 @@ New-Item -ItemType Directory -Force -Path $installDir | Out-Null
if (Test-Path $shimPath) {
$contents = Get-Content $shimPath -Raw
- if (-not $contents.Contains("cap-cli.exe")) {
+ if (-not ($contents.Contains($cliTarget) -or $contents -match '\\Cap\\cap-cli\.exe')) {
Write-Error "$shimPath already exists and is not managed by Cap. Remove it or set CAP_CLI_INSTALL_DIR, then run this script again."
exit 1
}