用vs的devenv.com命令行 自动编译 程序

vs2008怎么用devenv.com命令行自动编译?

其实在vs2008目录下面提供了devenv.com命令行方式,我们可以从VS安装目录..\Microsoft Visual Studio 9\Common7\IDE下面找到它,以下是几个常见用法:

用法:

devenv.com [solutionfile | projectfile |anyfile.ext] [switches]





set DEV_PATH="C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.com"
set WARE_PATH="../../../WarePlugin/solution/WarePlugin.sln"
set NWARE_PATH="../../../NWarePlugin/solution/NwarePlugin.sln"
set TRADE_PATH="../../../TradePlugin/solution/TradePlugin.sln"
set GLOD_PATH="../../../GoldPricePlugin/solution/GoldPricePlugin.sln"

@echo =====================================
@echo 正在编译主工程文件文件...
%DEV_PATH% "../../solution/WorkStation.sln" /rebuild Release /out main.txt

@echo =====================================
@echo 正在编译WARE...
%DEV_PATH% %WARE_PATH% /rebuild Release /out ware.txt

@echo =====================================
@echo 正在编译WARE...
%DEV_PATH% %NWARE_PATH% /rebuild Release /out nware.txt

@echo =====================================
@echo 正在编译TRADE...
%DEV_PATH% %TRADE_PATH% /rebuild Release /out trade.txt

@echo =====================================
@echo 正在编译GLOD...
%DEV_PATH% %GLOD_PATH% /rebuild Release /out glod.txt

你可能感兴趣的:(vs2010)