Managed Neovim + WezTerm CI Smoke Checks

3 min read · docs/ci-smoke-checks-terminal.md · View source on GitHub ↗

The CI matrix includes an isolated full lifecycle on Ubuntu, macOS, and Windows. It plans and applies the minimal profile, renders local override templates, verifies a second apply is idempotent, exercises backup/remove/restore, checks doctor text and JSON, and injects a transactional failure to verify automatic rollback. The test sets temporary HOME/XDG roots and disables dependency and network installation.

Additional validation now includes all tracked maintained Bash files, all setup and wrapper PowerShell files, tracked JSON/TOML/YAML/KDL/Lua configuration, generated lock and completion drift, Python 3.12 and 3.13, and a 50% Python coverage floor.

This note documents the low-risk CI checks for managed terminal/editor config under:

  • home/.config/nvim/
  • home/.config/wezterm/
  • home/.config/ghostty/

What exists today (relevant context)#

  • Neovim config bootstraps lazy.nvim by cloning from GitHub if missing, then loads plugin spec/imports via LazyVim.
  • WezTerm config is modular Lua, with dynamic event/module loading and optional local override from ~/.config/ooodnakov/local/wezterm.lua.
  • Ghostty config is a single key = value file with an optional config-file include for ~/.config/ooodnakov/local/ghostty.conf; the Noctalia theme lives in home/.config/ghostty/themes/Noctalia.
  • .github/workflows/ci.yml runs static smoke checks for managed Neovim, WezTerm, and Ghostty config on Linux, macOS, and Windows, alongside shell syntax, Python lint/format, lock reproducibility, optional-dependency drift, and oooconf smoke checks.

Definitely safe now (low flake risk)#

These checks are deterministic and do not depend on GUI/session state.

Neovim#

  1. JSON validity checks - Validate home/.config/nvim/lazy-lock.json - Validate home/.config/nvim/lazyvim.json - Command idea: python3 -m json.tool <file> > /dev/null
  2. Managed file presence checks - Ensure at least these files exist:
    • home/.config/nvim/init.lua
    • home/.config/nvim/lua/config/lazy.lua

WezTerm#

  1. Managed entrypoint presence checks - Ensure these files exist:
    • home/.config/wezterm/wezterm.lua
    • home/.config/wezterm/config/init.lua
  2. Reference asset presence checks (if configured as defaults) - If a default backdrop list is expected, ensure files referenced by default config exist.

Ghostty#

  1. Managed entrypoint presence checks - Ensure these files exist:
    • home/.config/ghostty/config
    • home/.config/ghostty/themes/Noctalia
  2. Static syntax and reference checks - Parse every non-comment line as key = value - Ensure each keybind value contains both a trigger and an action - Ensure the configured theme file exists under home/.config/ghostty/themes/ - Ensure the config-file include stays optional (? prefix) so a fresh clone works without a local override - Ensure every custom-shader path exists and defines mainImage - Ensure the theme defines palette indexes 0–15 as hex colors

Possible with extra setup (good value, but adds runtime/dependency complexity)#

Neovim (macOS)#

  1. Headless startup sanity - Install Neovim in CI. - Run with isolated temp dirs to avoid mutating runner state:

    • XDG_CONFIG_HOME=$PWD/home/.config
    • temp XDG_DATA_HOME/XDG_STATE_HOME/XDG_CACHE_HOME
    • Example: nvim --headless '+qall'
    • Caveat: first run may clone lazy.nvim; plugin bootstrap/network outages can make this flaky.
  2. Pinned plugin lock consistency - Run Lazy lock/check command headlessly and compare lockfile diff. - Useful, but more likely to break due to upstream/plugin API changes.

WezTerm (Windows)#

  1. Config load check via WezTerm CLI - Install WezTerm in CI. - Run a command that loads config without opening a full GUI session (platform-specific). - Caveat: runner platform differences and font availability can cause false negatives.

  2. Lua syntax check for all WezTerm Lua files - Install Lua toolchain and run parse-only checks (luac -p) for home/.config/wezterm/**/*.lua. - Useful but requires consistent Lua version and package availability.

Not worth automating (at least initially)#

  1. Visual appearance checks (themes, blur/background rendering, glyph aesthetics) - High maintenance, low signal for CI.
  2. Interactive keybinding ergonomics - Better validated manually on real machines.
  3. Plugin functional behavior requiring external tools - Example: lazygit plugin behavior depends on lazygit, git repo state, terminal semantics.

Implemented minimal checks#

The current CI keeps terminal/editor checks static and deterministic:

  1. Validate Neovim JSON files (lazy-lock.json, lazyvim.json).
  2. Verify core Neovim/WezTerm managed entrypoint files exist.
  3. Run deterministic WezTerm right-status Lua regressions for local, plain SSH, nested SSH, and SSH-domain host fallback (tests/test_wezterm_right_status.lua).
  4. Run cross-platform oooconf smoke checks (install --dry-run, expected-failing doctor on a fresh HOME, and lock).
  5. Validate lock artifacts with scripts/generate/generate_dependency_lock.py and targeted optional-dependency drift tests.

Why this shape:

  • Almost zero flake risk.
  • Minimal CI dependencies beyond Python, uv, shellcheck, and (on Linux) zsh plus Lua for the doctor and WezTerm checks.
  • Catches accidental deletes/corruption quickly.
  • Preserves reproducibility goals while keeping CI fast.

Suggested next phase#

After the first phase stabilizes, add optional/non-blocking headless startup checks behind a separate job or matrix entry, so regressions are visible without making every PR flaky.