Created
August 15, 2021 03:52
-
-
Save anderslanglands/56caaf7617185b9d4627c03b8ec89ecf to your computer and use it in GitHub Desktop.
conda vcvars setup
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Setup VS environment | |
cmd.exe /c "set > %temp%\vcvars_before.txt" | |
cmd.exe /c "call `"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvars64.bat`" && set > %temp%\vcvars_2019.txt" | |
Get-Content "$env:temp\vcvars.txt" | Foreach-Object { | |
if ($_ -match "^(.*?)=(.*)$") { | |
Set-Content "env:\$($matches[1])" $matches[2] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment