如何使用Sandcastle NuGet软件包(EWSoftware.SHFB)生成文档? [英] How to generate documentation using Sandcastle NuGet package (EWSoftware.SHFB)?
问题描述
我正在尝试使用Visual Studio(EWSoftware.SHFB)中的Sandcastle的NuGet包为C#代码生成网站文档.事实是我不知道如何使用它.我是从NuGet程序包管理器安装它的,然后我不知道如何处理它.
I am trying to generate website documentation for my C# code using the NuGet package of Sandcastle in Visual Studio (EWSoftware.SHFB). The fact is that I don't know how to use it. I install it from the NuGet package manager and then I have no idea what to do with it.
使用默认安装程序安装的VS Sandcaslte扩展名,我可以编辑自己的文档项目并生成相应的网站.
I have no problem to edit my documentation project and to generate the corresponding website using the VS Sandcaslte extension installed with the default installer.
谢谢您的帮助.
推荐答案
MsBuild.exe MyDocumentationProject.shfbproj
生成了文档.这意味着该项目无法通过VS进行编辑,但可以使用命令行来生成.
MsBuild.exe MyDocumentationProject.shfbproj
generated the documentation. It means that the project can not be edited via VS, but it can be generated using the command line.
之前,如 https://github.com/EWSoftware所述/SHFB/blob/master/NuGet/ReadMe.txt :
-
必须在
MyDocumentationProject.shfbproj
中设置ComponentPath
属性,以提供有关您所使用的框架的反射信息.
the
ComponentPath
property must be set inMyDocumentationProject.shfbproj
to provide reflection information regarding the framework you are using.
<PropertyGroup>
<ComponentPath>$(MSBuildThisFileDirectory)..\packages\EWSoftware.SHFB.NETFramework.4.6</ComponentPath>
</PropertyGroup>
必须在MyDocumentationProject.shfbproj
中有条件地设置SHFB环境变量.
The SHFB environment variable must be set conditionally in MyDocumentationProject.shfbproj
.
<PropertyGroup>
<SHFBROOT Condition=" '$(SHFBROOT)' == '' ">$(MSBuildThisFileDirectory)..\packages\EWSoftware.SHFB.2015.10.10.0\Tools\</SHFBROOT>
</PropertyGroup>
这篇关于如何使用Sandcastle NuGet软件包(EWSoftware.SHFB)生成文档?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!