Created
November 25, 2013 15:01
-
-
Save JakeGinnivan/7642509 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| function Get-Batchfile ($file) { | |
| $cmd = "`"$file`" & set" | |
| cmd /c $cmd | Foreach-Object { | |
| $p, $v = $_.split('=') | |
| Set-Item -path env:$p -value $v | |
| } | |
| } | |
| function VsVars32() | |
| { | |
| $vs120comntools = (Get-ChildItem env:VS120COMNTOOLS).Value | |
| $batchFile = [System.IO.Path]::Combine($vs120comntools, "vsvars32.bat") | |
| Get-Batchfile $BatchFile | |
| } | |
| "Initializing VS2013 Environment" | |
| # get VS tools | |
| VsVars32 | |
| # set VisualStudioVersion - this is set by vcvarsall.bat under VS 11 and is needed to correctly build | |
| # on a machine with both Dev10 and Dev11 installed. | |
| $Env:VisualStudioVersion = "12.0" | |
| # set environment variable to select between Dev10 and Dev11 projects in the various dirs.proj | |
| $Env:DevToolsVersion = "120" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment