How to programmatically list all properties defined while executing MSBuild?

谁说胖子不能爱 提交于 2019-12-23 07:06:03

问题


I'm looking for a way to access all the Build properties defined while executing MSBuild. I have a configuration file. I want to modify the Properties in the configuration file and copy it to a new location. Is there a way to do it?


回答1:


If you run the build with /verbosity:detailed or /verbosity:diagnostic you will get very detailed output of all the properties that was used during your build process. However I suspect you want to change a config type file after/before you copy the builded files to another location? In that case there is several mechanismes to do that, what we have found to work pretty good, is the MSBuildCommunity tasks that can be found here on code plex

If you would like to see some samples of this I would be glad to post them



来源:https://stackoverflow.com/questions/867691/how-to-programmatically-list-all-properties-defined-while-executing-msbuild

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!