Skip to main content

CLI reference

The npx and uvx entry points provide six commands: install, configure, preview, doctor, update, and uninstall.

Invocation​

wezterm-codex-status-line [global options] <command> [command options]

Global options come before the subcommand:

uvx wezterm-codex-status-line --json doctor
npx --yes wezterm-codex-status-line@0.1.2 doctor

With npx, the first --yes belongs to npx. To pass --yes to this CLI, write it after the package name:

npx --yes wezterm-codex-status-line@0.1.2 --yes install

Global options​

OptionPurpose
--codex-home <path>Override $CODEX_HOME or ~/.codex
--wezterm-module-dir <path>Override the ~/.config/wezterm module directory
--config-file <path>Choose the CLI configuration file
--jsonPrint command results as JSON
--no-colorDisable terminal preview colors
--yesSkip CLI confirmation; for install, selects the title-bridge setting
--versionPrint the package version

install​

Installs status line files and adds the Codex session-start hook.

OptionPurpose
--title-bridgeConfigure the Codex terminal title
--no-title-bridgeDo not configure the terminal title
--dry-runShow changes without writing files

Use an explicit title-bridge option in automation. macOS and Linux should use --no-title-bridge.

configure​

Edits the display configuration. Without options it opens the interactive wizard; --from imports a complete JSON file.

OptionPurpose
--from <path>Import a complete configuration JSON
--label <text>Set a 1–24 character label
--rows 1|2Set the number of status rows
--binding-mode auto|hook|heuristicSet the session binding mode
--segments <ids>Set field order, comma separated
--disable <ids>Set the hidden-field list; an empty string clears it
--powerline / --no-powerlineEnable or disable Powerline rendering
--theme-bg <#RRGGBB>Set the default background
--theme-fg <#RRGGBB>Set the default foreground
--theme-dim <#RRGGBB>Set the muted text color
--color <id:bg:fg>Set a field's colors; repeatable
--width <columns>Set CLI preview width; default 120
--dry-runValidate and preview without saving

--segments changes order only. Use --disable to hide valid fields.

preview​

Renders the current configuration with sample data without writing files.

OptionPurpose
--width <columns>Simulated terminal width; defaults to terminal width or 120
--state <path>Read custom preview state JSON

doctor​

Checks the installation and configuration:

CheckWhat it verifies
manifestbridge.json exists
lua_entry / lua_coreStatus line modules exist
asset_integrityInstalled files are present and unchanged
hookshooks.json contains this project's session hook
wezterm_requireWezTerm configuration calls require("codex_statusline")
configDisplay configuration is valid

doctor checks local files. Confirm a running session in WezTerm itself.

update​

Reinstalls assets from the current package while preserving user configuration.

OptionPurpose
--title-bridgeConfigure the terminal title if it was not enabled
--no-title-bridgeDo not enable it this time; existing title settings remain
--dry-runShow changes without writing files

uninstall​

Removes status line files and the session hook, and restores the terminal title from the installation record.

OptionPurpose
--purge-configAlso delete codex_statusline_config.json
--dry-runCheck conditions without writing files

Remove the module reference from WezTerm and reload it first. If it is still referenced, the command returns exit code 3.

JSON output and exit codes​

JSON results include schema, command, version, status, changes, warnings, and resolved paths. preview also includes rendered text.

Exit codeMeaning
0Success
1Execution failure, or doctor did not pass all checks
2Invalid arguments/configuration, or cancelled interaction
3An operation precondition was not met, such as a remaining WezTerm reference