Skip to content

CLI Companion

The oxideterm CLI provides headless inspection, automation, CI checks, migration, and recovery for OxideTerm data. It is a standalone Rust binary that links the same domain crates used by the native desktop app and reads the same persisted stores directly.

The desktop app does not need to be running for normal CLI management commands. There is no CLI server, local RPC protocol, or socket connection. The ssh command is the exception: it intentionally launches a temporary SSH terminal in the native GUI.

Release bundles include the CLI binary. Open Settings → General → CLI Companion and select Install. The app installs:

  • macOS/Linux: ~/.local/bin/oxideterm
  • Windows: %LOCALAPPDATA%\OxideTerm\bin\oxideterm.exe

You can also build it directly:

Terminal window
cargo build --release -p oxideterm-cli

Use another data directory or named profile when required:

Terminal window
oxideterm --config-dir <path> <command>
oxideterm --profile <name> <command>
OXIDETERM_CONFIG_DIR=<path> oxideterm <command>

Most commands support human-readable output and machine-readable JSON through --json or --format json. Use doctor --strict or a command-specific --strict option when warnings should fail CI.

State-changing commands use explicit safety controls:

OptionPurpose
--dry-runShow the planned change without writing
--yesConfirm a real write
--json / --format jsonReturn structured output for scripts
Terminal window
oxideterm paths --json
oxideterm diagnose --json
oxideterm doctor --strict
oxideterm report --json

Use report --bundle <path> to create a redacted support bundle. Review the bundle before sharing it.

Terminal window
oxideterm settings validate --strict
oxideterm settings sections --json
oxideterm settings get ai.providers --json
oxideterm settings set terminal.fontSize 14 --dry-run
oxideterm settings export --section appearance --json
oxideterm settings diff ./settings-snapshot.json --section appearance

set and unset update existing JSON paths. Preview writes with --dry-run, then repeat with --yes when the plan is correct.

Terminal window
oxideterm connections list
oxideterm connections search prod --json
oxideterm connections create --name prod --host example.internal --user deploy --port 22 --dry-run
oxideterm connections rename prod production --yes
oxideterm connections validate --strict
oxideterm connections export --format raw-safe --json
oxideterm forwards list --json
oxideterm forwards validate --strict

For passwords and passphrases, prefer stdin or environment options such as --password-stdin, --password-env, --passphrase-stdin, and --passphrase-env. Do not put secret values directly in shell arguments.

Terminal window
oxideterm backup create --output ./oxideterm-backup.json --json
oxideterm backup inspect ./oxideterm-backup.json --summary
oxideterm backup restore ./oxideterm-backup.json --section settings --dry-run --json

Review restore plans before confirming them with --yes.

Terminal window
oxideterm cloud-sync status --json
oxideterm cloud-sync diff --dirty-only --format table
oxideterm cloud-sync backend webdav configure --endpoint https://example.invalid/sync --dry-run
oxideterm cloud-sync push --dry-run --json
oxideterm cloud-sync pull --dry-run --json
oxideterm cloud-sync apply --from remote --strategy merge --dry-run
oxideterm cloud-sync secrets status --json

Cloud-sync secret commands report hints or status rather than secret values. Use stdin or environment variables when setting credentials.

Batch plans combine settings, connection snapshots, and cloud-sync configuration into one reviewed operation:

Terminal window
oxideterm batch apply ./plan.json --dry-run
oxideterm batch apply ./plan.json --yes --json
CommandPurpose
settingsRead, validate, diff, import, export, and edit settings
connectionsInspect and manage saved SSH connections and groups
sshOpen a temporary SSH terminal in the native desktop app
forwardsInspect and manage saved local, remote, and dynamic forwards
quick-commandsInspect and manage terminal Quick Commands
pluginsInspect plugin state and manage plugin settings
portableInspect and manage the portable runtime keystore
secretsInspect hints and manage keychain-backed secrets without printing values
oxideValidate, compare, import, and export encrypted .oxide bundles
cloud-syncConfigure and operate cloud sync, conflicts, history, and rollback state
pathsPrint resolved configuration and data paths
diagnosePrint a read-only diagnostics snapshot
doctorRun health checks for settings, connections, and cloud sync
backupPreview, create, inspect, verify, diff, and restore backups
batchReview and apply multi-step JSON plans
reportGenerate a redacted support report or bundle
completionGenerate, locate, or install shell completion scripts
errorsList stable machine-readable CLI error codes

Run oxideterm --help or oxideterm <command> --help for the exact options in your installed version.

Terminal window
oxideterm completion zsh > ~/.zfunc/_oxideterm
oxideterm completion path zsh
oxideterm completion install zsh

Completion generation supports Bash, Elvish, Fish, PowerShell, and Zsh. Use --force with completion install only when replacing an existing generated completion file.

  • Select the intended profile explicitly in scheduled jobs.
  • Prefer JSON output and stable CLI error codes for scripts.
  • Run validation and dry-run commands before writes.
  • Keep secrets out of command history and logs.
  • Do not assume the GUI is running; management commands are designed to operate headlessly.