Generating Documentation
DocFX - deploying API documentation to SQTechDocs
- Create a documentation folder in the repository root with the docfx.json and docmetadata files
- Identify your project ID, which will correspond to the SQTech docs URL/blob storage container.
- If using NukeExt as a library via a build project file:
- Add
[DocFXAzurePipelines("{yourprojectid}")]to yourBuildclass - Inherit from the interface ICreateDocFX.
- Add
- Otherwise, if using NukeTool:
- Specify “ProjectName” in parameters.json
- Run
build.cmd --generate-configuration AzurePipelines_docfx
- Create a new build pipeline to run the generated
azure-pipelines.docfx.ymlfile
Doxygen - deploying API documentation to SQTechDocs
- Create a documentation folder in the repository with the docmetadata file
- Identify your project ID, which will correspond to the SQTech docs URL/blob storage container.
- Add
[DoxygenAzurePipelines("{yourprojectid}")]to yourBuildclass. - Inherit from the interface ICreateDoxygen.
- Create a new build pipeline to run the generated
azure-pipelines.doxygen.ymlfile
DocFX/Doxygen - adding last modified date to HTML pages
-
Add a reference to the NuGet package Microsoft.XboxStudios.NukeExt.Documentation.LastModified. For example:
<ItemGroup Condition="'$(GenerateDocs)' == 'true'"><PackageReference Include="Microsoft.XboxStudios.NukeExt.Documentation.LastModified" Version="1.1.1" /></ItemGroup> -
Inherit from ICreateDocFXLastModifiedStamp instead of ICreateDocFX, or ICreateDoxygenLastModifiedStamp instead of ICreateDoxygen.
-
Configure as needed for your project, by overriding properties in the ICreateLastModifiedStamp interface:
-
All files that match the pattern
**/*.mdin the root documentation directory will be stamped with the last modified date except forapi/*.md. To use different files, override theIncludeDocumentationFilePatternsorExcludeDocumentationFilePatternsproperties. -
Note documentation files must be tracked by git to retrieve the last modified date.
-
By default, the last modified stamp is inserted with a line break at the HTML node
//article[contains(@class, 'content wrap')]. To use a different HTML node, override theLastModifiedHtmlNodeproperty. -
By default, the last modified stamp is appended to the HTML node. To change the placement of the stamp, override the
LastModifiedStampPlacementproperty. -
To disable the line break, override the
InsertLineBreakAfterLastModifiedproperty tofalse.
-