在南特,我有一个非常简单的属性来获取我的项目的根,它看起来像这样...得到父目录中的MSBuild
<property name="project.root.folder"
value="${directory::get-parent-directory(directory::get-parent-directory(project.local.folder))}" />
这需要我,我的项目的根从我建立了我所有的路径。
在MSBuild中,我可以使用$(MSBuildProjectDirectory)来获取当前目录,但是我想要获取父目录的完整路径。 NAnt使用目录:: get-parent-directory作为一个魅力,并希望在MSBuild中有类似的东西。
我发现了一个以前的类似问题(http://stackoverflow.com/questions/514264/msbuild-find-msbuildprojectdirectory-parent-directory)但我想一定有更简单的可用,肯定!
山姆:)
看起来像什么?啊哈,给你修好了! – alternative 2011-06-07 21:51:09
哈哈,不知道你是怎么做到的,但谢谢! – samaspin 2011-06-07 21:55:42
BAMBAM:缩进4个空格。 – alternative 2011-06-07 23:57:47