I'm working on a unity / C# project. I've added many documentation comments throughout the project (in the style of ///<summary></summary>
) as is the standard for C# projects.
I can't seem to figure out how to just simply generate markdown from these comments. I've searched everywhere and the only tools I've found either only generate html, require you to use custom attributes on everything, or just simply don't work. I'm at a loss because this seems like a very common thing to want to do, but there doesn't seem to be anything out there that does this. Does anybody know of the correct tool?
CodePudding user response:
I discovered that unity doesn't actually generate the XML documentation for projects for some reason. You must follow these steps:
- go to Tools > Options > Tools For Unity.
- Set "Disable Full Build of Projects" to false and "Access to Project Properties" to true.
- Click okay and restart Visual Studio.
- Right click on the project you want to generate documentation for and click "Properties" (note: this will not work if you didn't enable access to project properties in step 2)
- In project properties, go to Build > Output and make sure "XML Documentation" is checked
Now that generating XML actually works, you can use vs2doc or DefaultDocumentation to generate the markdown