Skip to main content

Module output

Module output 

Source

Modules§

exit_codes

Structs§

OutputConfig

Enums§

OutputFormat

Functions§

colored_entity_id
Dim the domain prefix of an entity ID, leaving the name at normal brightness. light.left_key_light[dim]light.[/dim]left_key_light
colored_state
Color a Home Assistant state value for human display.
kv_block
Render a two-column key/value block with aligned values.
mask_credential
Mask a credential for safe display. Keeps first 6 and last 4 chars for long values; fully obscures short values.
relative_time
Format an ISO 8601 timestamp as a human-friendly relative time (“2m ago”). Falls back to the raw string if parsing fails.
table
Render a table with bold headers, dimmed separator, and ANSI-aware column alignment. Rows may contain pre-colored strings; alignment is based on visible width. Automatically shrinks the widest column(s) to fit within the terminal width.