So I have a command I want to run which looks like the following:
for /r %n in ("*.vdproj") do "C:/Program Files/Microsoft
Visual Studio 10.0/Common7/IDE/devenv.exe" %n /build "BuildServer"
It seems to work in that it runs devenv on each .vdproj file; however, it seems to run them in parallel and immediately return. This is a problem; I need to wait until they are all finished before the next step in the .bat file runs. How can I either
1- Get for to 'wait' on each devenv to finish before running the next one
or
2- Wait until devenv.exe is all done before moving on afterwards?
Right click the lsiting and choose Details. Select the devenv.exe process on the details page and then click the End Task button. Confirmation window ...don you want to end this task? Click on End Process.
"Devenv.exe" is the central Integrated Development Environment (IDE) for Microsoft's Visual Studio suite used worldwide to develop applications for multiple platforms in over twenty programming languages. It installs in a subfolder of "C:\Program Files", ("C:\Program Files(x86)" on 64-bit systems).
The trick is to use devenv.com
instead of devenv.exe
. devenv.com
will return output to the console and achieve exactly the desired result.
Invoke devenv.exe using start
, e.g.
start /wait "" "C:/Program Files/Microsoft Visual Studio 10.0/Common7/IDE/devenv.exe" %n /build "BuildServer"
Use start /?
for usage.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With