Is there any powershell script exist to build visual studio project without open visual studio?
1 Answer
You don't even need power shell or visual studio. Just use the msbuild program installed with .Net. Usage example is like this:
msbuild DBMigration.csproj /p:Configuration=Debug
msbuild is located at C:\Windows\Microsoft.NET\Framework\v3.5 (or select your version)
There is also a powershell build system, https://github.com/JamesKovacs/psake
2 Comments
Markus L
I've found msbuild in
C:\Program Files (x86)\MSBuild\14.0\Bin!not2qubit
For VS2022 its found in:
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\MSBuild.exe and C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\MSBuild.exe