archdoc

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 14, 2026 License: Apache-2.0 Imports: 7 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package archdoc writes architecture documentation from one scan and its map: Markdown with arc42 sections and C4 context and container views in Mermaid. Every statement carries a footnote with the facts behind it and their file and line. Deterministic: the same scan, map and options give the same bytes. Sections the code cannot answer (goals, decisions, quality) are left blank for a person to write. See https://cernly.dev/how/architecture-docs/.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(s *fact.Scan, m *rules.Map, o Options) []byte

Build writes the Markdown document.

Types

type Options

type Options struct {
	Version string           // the cernly version, printed in the header
	Words   map[string]Words // per finding rule; optional
	// Labels names stacks for a reader (a declared display name); optional.
	Labels map[string]string
	// MaxEvidence is the number of places listed per fact (default 5).
	MaxEvidence int
}

type Words

type Words struct {
	Title, Meaning, Action string
}

Words explain a finding rule to a reader. A caller can pass its own; with none, the rule id is printed.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL