generate-notes

command
v0.3.9 Latest Latest
Warning

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

Go to latest
Published: May 7, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

hack/generate-notes/main.go

Generates pkg/note/catalog_generated.go from the markdown doc files in pkg/note/docs/.

Usage:

go run ./hack/generate-notes
make generate-notes

The generator parses every *.md file in docs/ and extracts note entries from ### `noteName` headings. The first non-empty paragraph after the heading becomes the description. The first fenced code block becomes the example. Some headings document two notes together using the form:

### `toLower` / `toUpper`

In that case both names are registered with the same description and example.

The domain is derived from the filename: "01-strings.md" → "strings".

Jump to

Keyboard shortcuts

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