fire-eggs / CivOne

An open source implementation of Sid Meier's Civilization 1 using C# and .NET.
Creative Commons Zero v1.0 Universal
21 stars 4 forks source link

Use documentation in comments to generate pages in wiki #137

Open iegik opened 3 years ago

iegik commented 3 years ago
  1. https://github.com/SWY1985/CivOne/wiki
  2. https://github.com/fire-eggs/CivOne/wiki
  3. Documentation in comments
/// <summary>
/// Modify the unit attack strength.
/// </summary>
/// <param name="value">The new attack strength for the unit. (valid range: 0 to 99)</param>
public Attack(byte value) : base(typeof(byte), value, InRange)
{
}

There is a several plugins and tools that can compile comments in the code into reach documentation. We should try that.

For example, we can document interfaces


Related links:

fire-eggs commented 3 years ago

Related: issue #104

iegik commented 3 years ago

This issue mostly about two questions:

For example (pseudo code): docgen --prefix="API~" src/**/*.cs ../CivOne.wiki/API/ will generate pages like API/API~Settlers.md

fire-eggs commented 3 years ago

https://github.com/eneko/SourceDocs https://github.com/mkdocs/mkdocs/ https://dotnet.github.io/docfx/

https://marketplace.visualstudio.com/items?itemName=PeterMacej.VSdocman https://www.doxygen.nl/index.html