chore: align install flow with latest OpenClaw and remove marketing copy
This commit is contained in:
@@ -143,43 +143,31 @@ if (Get-Command git -ErrorAction SilentlyContinue) {
|
||||
}
|
||||
|
||||
# ─────────────────────────────────────────────
|
||||
# Step 3: Install OpenClaw
|
||||
# Step 3: Install / Update OpenClaw
|
||||
# ─────────────────────────────────────────────
|
||||
Write-Info "Checking OpenClaw..."
|
||||
Write-Info "Installing / updating OpenClaw..."
|
||||
|
||||
$needsInstall = $true
|
||||
npm install -g openclaw@latest 2>&1 | Write-Host
|
||||
if ($LASTEXITCODE -ne 0) {
|
||||
Write-Err "OpenClaw installation failed. Please run manually: npm install -g openclaw@latest"
|
||||
}
|
||||
|
||||
# Refresh PATH
|
||||
$env:Path = [System.Environment]::GetEnvironmentVariable("Path", "Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path", "User")
|
||||
|
||||
# Add npm global bin to PATH
|
||||
try {
|
||||
$null = Get-Command openclaw -ErrorAction Stop
|
||||
Write-Ok "Found OpenClaw."
|
||||
$needsInstall = $false
|
||||
} catch {
|
||||
Write-Info "Installing OpenClaw..."
|
||||
}
|
||||
|
||||
if ($needsInstall) {
|
||||
npm install -g openclaw@latest 2>&1 | Write-Host
|
||||
if ($LASTEXITCODE -ne 0) {
|
||||
Write-Err "OpenClaw installation failed. Please run manually: npm install -g openclaw@latest"
|
||||
}
|
||||
|
||||
# Refresh PATH
|
||||
$env:Path = [System.Environment]::GetEnvironmentVariable("Path", "Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path", "User")
|
||||
|
||||
# Add npm global bin to PATH
|
||||
try {
|
||||
$npmPrefix = (npm config get prefix 2>$null).Trim()
|
||||
if ($npmPrefix) {
|
||||
$userPath = [Environment]::GetEnvironmentVariable("Path", "User")
|
||||
if (-not ($userPath -split ";" | Where-Object { $_ -ieq $npmPrefix })) {
|
||||
[Environment]::SetEnvironmentVariable("Path", "$userPath;$npmPrefix", "User")
|
||||
$env:Path += ";$npmPrefix"
|
||||
}
|
||||
$npmPrefix = (npm config get prefix 2>$null).Trim()
|
||||
if ($npmPrefix) {
|
||||
$userPath = [Environment]::GetEnvironmentVariable("Path", "User")
|
||||
if (-not ($userPath -split ";" | Where-Object { $_ -ieq $npmPrefix })) {
|
||||
[Environment]::SetEnvironmentVariable("Path", "$userPath;$npmPrefix", "User")
|
||||
$env:Path += ";$npmPrefix"
|
||||
}
|
||||
} catch {}
|
||||
}
|
||||
} catch {}
|
||||
|
||||
Write-Ok "OpenClaw installed."
|
||||
}
|
||||
Write-Ok "OpenClaw installed / updated."
|
||||
|
||||
# ─────────────────────────────────────────────
|
||||
# Step 3: Launch interactive setup
|
||||
@@ -189,12 +177,8 @@ Write-Host "========================================" -ForegroundColor Green
|
||||
Write-Host " OpenClaw installed! Starting setup..." -ForegroundColor Green
|
||||
Write-Host "========================================" -ForegroundColor Green
|
||||
Write-Host ""
|
||||
Write-Host " Tip: When the setup wizard asks for a provider," -ForegroundColor White
|
||||
Write-Host " choose MiniMax for a 7-day free trial - no credit card needed." -ForegroundColor White
|
||||
Write-Host " Sign up: https://platform.minimax.io" -ForegroundColor Cyan
|
||||
Write-Host ""
|
||||
|
||||
openclaw onboard --accept-risk --flow quickstart --node-manager npm --skip-skills
|
||||
openclaw onboard --accept-risk --flow quickstart --install-daemon --node-manager npm --skip-skills
|
||||
|
||||
Write-Host ""
|
||||
Write-Host "========================================" -ForegroundColor Green
|
||||
|
||||
Reference in New Issue
Block a user