CLI Reference

ProtoML currently exposes these main binaries: protoml-parser, protoparser, protoml-viewer, and protoviewer.

Main syntax

protoparser [options] <filename> <format>
protoparser [options] <filename> <format> <output_dir>

Main render formats

protoparser "test.pml" html
protoparser "test.pml" pdf
protoparser "test.pml" json
protoparser "test.pml" markdown
protoparser "test.pml" text

Most users should think of these as three classes of outputs: reader-facing rich output, archival/static output, and machine-readable output.

Analysis and validation

protoparser validate "test.pml"
protoparser tags "_tags.pml" validate
protoparser tags "_tags.pml" statistics
protoparser macros "test.pml"
protoparser trust "test.pml"
protoparser analyze "test.pml" statistics
protoparser analyze "test.pml" graph
protoparser register "meetings" statistics
protoparser bundle "test.pml"

These commands are where ProtoML stops being just a renderer and starts acting like a document system. They let you inspect structure, governance metadata, tag usage, macro usage, import relationships, and document trust state.

register here means a governance report over document folders. It is separate from macro registries and the macro_install ..._registry commands used for external macro packs.

Project and packaging commands

protoparser scaffold meeting "./demo"
protoparser init "./project"

Use these when you want a repeatable starting structure instead of hand-creating the first files.

Macro commands

protoparser --listMacros "{{macro_dir}}"
protoparser --macroHelp "{{macro_dir}}/finance/f_entry.pml"
protoparser --listMacrosJson "{{macro_dir}}"

These are especially useful when a team wants to discover what is already bundled before inventing new macros.

Documentation commands

protoparser --listDocs
protoparser --docs meeting
protoparser chm
protoparser chm path
protoparser chm download

The built-in docs help with precise topic lookup, while the CHM guides are better for learning and orientation.

Trust and signing commands

protoparser trust "test.pml"
protoparser sign macro "./macros/warn_box.pml" "./keys/alice-private.pem" "Alice" alice-main
protoparser sign pml "./governance/release-approval.pml" "./keys/alice-private.pem" "Alice" alice-main
protoparser verify macro "./macros/warn_box.pml" -trustRegistry="./my-registry"
protoparser verify pml "./governance/release-approval.pml" -trustRegistry="./authors-registry"

These commands provide the lightweight trust workflow: static risk checks, detached signatures, and author trust lookup via registry sources. The same detached signature model works for normal governance-style .pml files as well as macros.

Useful options

Common workflow patterns

Verbosity

Related guides