0

When attempting to use Docfx to document a C# project I am running into an issue that is probably down to myself being a moron. However I have read through the docfx examples and I have not seen any obvious ways of rectifying the issue.

When I run docfx init -q I get no errors. When I run docfx docfx.json --serve I also get no errors, upon completed I get a Build succeeded. 0 Warnings 0 Errors message however no html files are generated.

It also appears to be correctly reading the source files from my project as the api folder has yml files with the same names as the class files in the project.

How do I get docfx to generated the appropriate html files for the project. Full output of docfx docfx.json --serve is below:

[19-07-04 05:07:47.020]Info:[MetadataCommand.ExtractMetadata]Using msbuild C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin as inner compiler.
[19-07-04 05:07:47.302]Info:[MetadataCommand.ExtractMetadata]Loading projects...
[19-07-04 05:07:50.379]Info:[MetadataCommand.ExtractMetadata]'C:/Users/Devvy/Source/Repos/TestProj/TestProj.csproj,C:/Users/Devvy/Source/Repos/TestProj/Display_Output.cs,C:/Users/Devvy/Source/Repos/TestProjException.cs,C:/Users/Devvy/Source/Repos/TestProj_Core.cs,C:/Users/Devvy/Source/Repos/TestProj/Module_Info.cs,C:/Users/Devvy/Source/Repos/TestProj/Opcode_Assembler.cs,C:/Users/Devvy/Source/Repos/TestProj/Opcode_Disassembler.cs,C:/Users/Devvy/Source/Repos/TestProj/Pattern_Tools.cs,C:/Users/Devvy/Source/Repos/TestProj/Payloads.cs,C:/Users/Devvy/Source/Repos/TestProj/Process_Info.cs,C:/Users/Devvy/Source/Repos/TestProj/PtrRemover.cs,C:/Users/Devvy/Source/Repos/TestProj/RopChainGenerator32.cs,C:/Users/Devvy/Source/Repos/TestProj/RopChainGenerator64.cs,C:/Users/Devvy/Source/Repos/TestProj/Thread_Info.cs,C:/Users/Devvy/Source/Repos/TestProj/obj/Debug/net472.AssemblyInfo.cs,C:/Users/Devvy/Source/Repos/TestProj/obj/Debug/net472/TestProj.AssemblyInfo.cs,C:/Users/Devvy/Source/Repos/TestProj/obj/Debug/net472_Lib.AssemblyInfo.cs,C:/Users/Devvy/Source/Repos/TestProj/obj/Debug/net472/TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs,C:/Users/Devvy/Source/Repos/TestProj/obj/Debug/net472/TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs,C:/Users/Devvy/Source/Repos/TestProj/obj/Debug/net472/TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs,C:/Users/Devvy/Source/Repos/TestProj/obj/Debug/netstandard2.0.AssemblyInfo.cs,C:/Users/Devvy/Source/Repos/TestProj/obj/Release/net472/TestProj.AssemblyInfo.cs' keep up-to-date since '7/4/2019 5:03:14 PM', cached result from 'C:/Users/Devvy/Source/Repos/TestProj/Documentation/api' is used.
[19-07-04 05:07:50.379]Info:[MetadataCommand]Completed Scope:MetadataCommand in 3384.2278 milliseconds.
[19-07-04 05:07:50.379]Info:Completed in 3389.2213 milliseconds


Build succeeded.
    0 Warning(s)
    0 Error(s)
Ted
  • 1

1 Answers1

0

Docfx provides static code documentation for us. If you want to static website of output with docfx correctly. You should follow these steps;

First you must install docfx. You have many way but I recommend install with choco

choco install docfx -y

then you must add your project docfx console package from NuGet

Install-Package docfx.console -Version 2.33.0

now open your project folder or whatever you want create a folder then run like that

docfx init 

now best part of this answer you must config you'r project docfx.json file like this

after run

docfx --serve

Also I found a example project here

I think your problem about you're docfx file configuration.

errorau
  • 2,121
  • 1
  • 14
  • 38