开发者

Measuring total solution build time in Visual Studio [duplicate]

开发者 https://www.devze.com 2022-12-09 13:51 出处:网络
This question already has answers here: 开发者_开发知识库 Displaying build times in Visual Studio
This question already has answers here: 开发者_开发知识库 Displaying build times in Visual Studio (13 answers) Closed 9 years ago.

Does any know if there is any native mechanism to report on the total solution build time in Visual Studio 2008? You can change the build verbosity to report build times per project as discussed here or report total build time from msbuild but I’d like to see this in the IDE across an entire solution containing many projects. Short of creating custom pre and post build events, does anyone know if there’s any native output for total build time? Thanks!


For the sake of completeness, the correct answer is "No, you can't report on total solution build time directly within Visual Studio".


Not native and not not for VS 2008 (currently only for VS 2010), but the VSCommands 2010 extension provides these statistics.

See also: VS 2010: Prevent display of Build Summary in the output window


MSBuild will show the total build time when you run it from the command prompt, e.g:

> msbuild MySolution.sln
...
Time Elapsed 00:00:36.94


There's also an easy way to measure the build time per project in Visual Studio 2010. I'm pretty sure it will work in Visual Studio 2008, too. All you have to do is to go to Tools -> Options -> Projects and Solutions -> Build and Run and set the MSBuild project build output verbosity to "Normal" or "Detailed" (I recommend "Normal", as detailed gives too much information).


I think you could probably hook into the OnBuildBegin and OnBuildDone events

http://visualstudiohacks.com/general/customize-your-project-build-process/


In VC++2008, there is the "Build Timing' option in Tools / Options / Projects and solutions / VC++ Project Settings

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号