'devenv.exe exits instead of build (Visual Studio Community 2019)
Scenario:
- Open Visual Studio 2019 Developer Command Prompt v16.3.5
cd c:\some_solution
devenv.exe libogg.sln /Build
- devenv.exe immediately exits instead of build! Very disappointed...
.
Why and how to solve?
P.S. In GUI mode VS builds libogg.sln
as expected.
P.P.S. Product info:
Microsoft Visual Studio Community 2019
Version 16.3.5
VisualStudio.16.Release/16.3.5+29411.108
Microsoft .NET Framework
Version 4.8.03752
Solution 1:[1]
devenv.exe will work, but will not direct output to the console. Use devenv.com if you want to see the output.
Commands that begin with devenv are handled by the devenv.com utility, which delivers output through standard system streams, such as stdout and stderr. The utility determines the appropriate I/O redirection when it captures output, for example to a .txt file.
Alternatively, commands that begin with devenv.exe can use the same switches, but the devenv.com utility is bypassed. Using devenv.exe directly prevents output from appearing on the console.
https://docs.microsoft.com/en-us/visualstudio/ide/reference/devenv-command-line-switches
Solution 2:[2]
Yes this is exit immediately, but it is doing its operation on our backend, actually, it is building the package. you can verify this from your File Explorer. If you want to know what is exactly happening while applying devenv.exe *.sln /Build
then you have to use devenv.com *.sln /Build
. this command will give you a detailed log while it's running.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | Willem |
Solution 2 | chiducaf |