How to get cmd line build command for VS solution?

前端 未结 6 837
名媛妹妹
名媛妹妹 2020-12-02 17:28

This is probably easy but I am getting stuck: when I build a solution in Visual Studio - how do extract the exact cmd line for the current build command in order to be able

6条回答
  •  有刺的猬
    2020-12-02 17:51

    I just want to thank the Bejoy on the example. I had big problems with solution rebuild on setup pre build event because they removed most of the macros and this helped me a lot.

    Here is my solution based on Bejoy's (considering that .bat file is located in setup root folder which is part of solution):

    call "%VS100COMNTOOLS%\vsvars32.bat"
    
    devenv "%CD%\..\soulutionfile.sln" /build "Release"
    

提交回复
热议问题