Code and terminal
Commands, source explanations, diffs, and API endpoints.
Terminal
The terminal distinguishes commands, comments, and output. Set the prompt
and comment characters in metadata. The copy button copies executable
commands only. It does not copy prompt characters, complete comment lines, or
command output. Set title and frame (macos, windows, linux, or
plain) as metadata.
# Check the site before the production build.
$ mpress check
No issues found.
$ mpress build --strict
Built 15 pages in 24ms.
@terminal{title="Build the documentation" frame="macos" prompt="$" comment="#"}
# This line is visible but is not copied.
$ mpress check
No issues found.
@endDiffs
− colorScheme: light− search: false+ colorScheme: system+ search: true
Use the default mode="side-by-side" for a two-column comparison.
Explained code
func main() { site.Build()}1The program starts with a regular Go entry point.
2One call turns the content tree into the static site.
Point to or focus a numbered code line to open its explanation. Select the line on a touch screen.
API endpoints
/v1/builds
Creates a documentation build.
| Field | Type | Required |
|---|---|---|
ref |
string | yes |
strict |
boolean | no |