diff --git a/.github/workflows/integration-test-migrate-node-macos-fnm.yml b/.github/workflows/integration-test-migrate-node-macos-fnm.yml index b876bc2..77f655d 100644 --- a/.github/workflows/integration-test-migrate-node-macos-fnm.yml +++ b/.github/workflows/integration-test-migrate-node-macos-fnm.yml @@ -51,7 +51,8 @@ jobs: - name: "Migrate fnm Node.js to dtvem" run: | echo "=== Running migrate detection ===" - echo -e "1\n0\nn\n" | ./dist/dtvem migrate node || true + # Select "all" to migrate all detected versions (system + fnm) + echo -e "all\n0\nn\n" | ./dist/dtvem migrate node || true echo "" echo "=== Verifying migration ===" ./dist/dtvem list node diff --git a/.github/workflows/integration-test-migrate-node-windows-nvm.yml b/.github/workflows/integration-test-migrate-node-windows-nvm.yml index b865dd4..8680fea 100644 --- a/.github/workflows/integration-test-migrate-node-windows-nvm.yml +++ b/.github/workflows/integration-test-migrate-node-windows-nvm.yml @@ -41,12 +41,17 @@ jobs: shell: pwsh run: | choco install nvm -y - $env:Path = [System.Environment]::GetEnvironmentVariable("Path","Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path","User") + # Add nvm to GITHUB_PATH for subsequent steps + $nvmHome = [System.Environment]::GetEnvironmentVariable("NVM_HOME", "Machine") + if (-not $nvmHome) { $nvmHome = "C:\ProgramData\nvm" } + $nvmSymlink = [System.Environment]::GetEnvironmentVariable("NVM_SYMLINK", "Machine") + if (-not $nvmSymlink) { $nvmSymlink = "C:\Program Files\nodejs" } + "$nvmHome" | Out-File -FilePath $env:GITHUB_PATH -Append + "$nvmSymlink" | Out-File -FilePath $env:GITHUB_PATH -Append - name: "Install Node.js 20.18.0 via nvm-windows" shell: pwsh run: | - $env:Path = [System.Environment]::GetEnvironmentVariable("Path","Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path","User") nvm install 20.18.0 nvm use 20.18.0 Write-Host "nvm-windows Node.js version:" @@ -56,7 +61,8 @@ jobs: shell: bash run: | echo "=== Running migrate detection ===" - echo -e "1\n0\nn\n" | ./dist/dtvem.exe migrate node || true + # Select "all" to migrate all detected versions (system + nvm) + echo -e "all\n0\nn\n" | ./dist/dtvem.exe migrate node || true echo "" echo "=== Verifying migration ===" ./dist/dtvem.exe list node