fix: use dot-sourcing instead of child PowerShell process
powershell -File runs script in child process — PATH changes don't persist. Changed to Set-ExecutionPolicy + dot-sourcing (. script.ps1) which runs in current session. Also added PATH restart hint to Codex install/update scripts. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -234,3 +234,6 @@ try {
|
||||
}
|
||||
|
||||
Write-Host ""
|
||||
Write-Host " NOTE: If 'codex' is not recognized, restart PowerShell or run:" -ForegroundColor Yellow
|
||||
Write-Host ' $env:Path = [System.Environment]::GetEnvironmentVariable("Path","Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path","User")' -ForegroundColor Yellow
|
||||
Write-Host ""
|
||||
|
||||
Reference in New Issue
Block a user