.NET DocFX

This documentation was generated with the assistance of AI. Please report any inaccuracies.

Audit given C# class(es)/type(s) for complete XML doc-comment coverage, generate whatever is missing grounded in the actual code and current changes, then attempt a best-effort documentation report via DocFX. Unlike the other skills in its group, iru-dotnet-docfx does modify files: it writes /// doc comments — but it never changes behavior, signatures, or non-doc-comment code, and test classes are exempt from the documentation requirement. This is the .NET/C# equivalent of iru-java-javadoc.

Purpose

iru-dotnet-docfx closes documentation gaps without assuming a fixed house style: it first discovers this project’s own doc-comment bar (contributor guide, <GenerateDocumentationFile>/CS1591 enforcement, StyleCop SA16xx rules, a docfx.json filter config, or observed practice in nearby types) and phrasing conventions, then audits every type/field/property/event/constructor/method/enum member/nested type in scope, fills in what’s missing, extends namespace-level documentation only where this project already uses that convention, and proves the result actually builds via DocFX where the tool is installed — installing it itself if it’s missing, and reporting plainly if that install fails rather than silently skipping the check.

Purpose group

Invocation

/iru-dotnet-docfx
/iru-dotnet-docfx <TypeName1,TypeName2,...>

Inputs

Argument Required Description Default

TypeName1,TypeName2,…​

No

Comma-separated type names or file paths to audit. A simple type name is located via find/grep across the whole repository. Any resolved file living in a test project (via its .csproj <PackageReference> or a .Tests/.UnitTests/*.IntegrationTests naming convention) is dropped from the audited/generated scope and called out in the final report, since test classes carry no doc-comment requirement here.

None — defaults to every non-test, non-generated .cs file touched by uncommitted changes plus commits on the current branch not yet on the base branch. If that default scope is empty, the skill tells the user there’s nothing to document and stops.

Outputs

  • Edits (via the Edit tool) to the in-scope type files, adding or completing XML doc comments — no logic, signatures, formatting outside the added comments, or member ordering is changed.

  • Namespace-level documentation (a NamespaceDoc marker type or docfx.json markdown override) extended or created, but only for a project that already uses one of those conventions — never introduced as a new convention by this skill.

  • A best-effort DocFX site build (docfx metadata + docfx build) confirming the doc comments in scope are well-formed, if docfx is installed (or installable via dotnet tool install -g docfx); a static site under _site/ (or the project’s configured build.dest) on success.

  • A plain-text report: per type, how many members were already documented vs. gaps found and filled (named); per namespace, whether namespace-level documentation applies at all and its status; any test-class argument excluded; whether the DocFX report was generated, or skipped (with the install error shown) because docfx couldn’t be installed.

  • No behavior/signature changes, no analyzer fixes outside doc comments, and no test changes.

Execution flow

flowchart TD A["Start /dotnet-docfx\n(optional type names or file paths)"] --> B{Argument given?} B -- yes --> C["Resolve each to a file;\ndrop test-project files from scope"] B -- no --> D["Scope to non-test .cs files touched by\nuncommitted changes + branch commits not on base"] C --> E{Scope empty?} D --> E E -- yes --> F["Tell user: nothing to document, stop"] E -- no --> G["Discover this project's doc-comment bar:\ncontributor guide, CS1591 enforcement,\nStyleCop SA16xx, docfx.json, observed practice"] G --> H["Skim existing well-documented types\nfor phrasing conventions"] H --> I["Audit each in-scope type: type-level,\nfields/properties/events,\nconstructors, methods, enum members"] I --> J["Check whether this project already uses\nnamespace-level documentation"] J --> K["Generate missing doc comments grounded in\nimplementation + git diff/log + conventions"] K --> L["Apply edits with the Edit tool"] L --> M{docfx installed?} M -- no --> N["Attempt dotnet tool install -g docfx"] N -- fails --> O["Report: code documented,\nDocFX report skipped, show install error"] N -- succeeds --> P M -- yes --> P["docfx metadata + docfx build\n(scaffold docfx.json via docfx init -y if missing)"] P -- fails/warns on in-scope files --> Q["Fix offending comments,\nre-run until clean"] P -- clean --> R["Report: per-type gaps filled,\nnamespace-doc status, build result,\n_site/ path"] Q --> R

Dependencies

Invokes

None — iru-dotnet-docfx is a leaf skill; it only runs dotnet/docfx commands, reads/edits C# source, and reports, it does not call any other skill in this catalog.

Invoked by

  • .NET Code One Task Group — Step 3, once per task group’s bucket, via the iru-gate-runner agent, to update XML doc comments for every type the bucket touched and confirm the DocFX build passes (or was skipped cleanly because docfx isn’t installed).

Source

SKILL.md on GitHub — the file this page was generated from.