I'm interested in how much time I am spending on building my projects every day. Is there any existing tool which provides such statistics?
Thanks!
MSBuild (what VisualStudio uses to build) can provide you with this information. Include in your msbuild.exe call the PerformanceSummary switch:
msbuild.exe your.sln /clp:PerformanceSummary ...
That will give you something like this at the end of your build run log:
Project Performance Summary: 374 ms your.sln 1 calls Target Performance Summary: ... 109 ms GetWinFXPath 1 calls 156 ms EntityDeploy 1 calls 390 ms Build 2 calls ... Time Elapsed 00:00:00.43
If you want a file that contains only this information, rather than having it written to your console, you can use this switch (with logfile set to some path):
/logger:FileLogger,Microsoft.Build.Engine;logfile=perf.log;encoding=Unicode;performancesummary
There is build event, you can use them, you can also run a batch script before and after a build to echo time >> filename
and then render the file and get your stats.
(goto build events in the project property page)
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