feat(terminal): Kitty only — drop Ghostty (#95)
Some checks failed
Check / eval (push) Has been cancelled

Ghostty's OpenGL 4.3 floor broke the Acer (HD 4000 / 4.2). Dual-terminal
support (default Ghostty + install-time Kitty fallback) was more complexity
than it was worth.

- Remove ghostty.nix / nomarchy.ghostty.enable
- Kitty always installed and themed from theme-state
- Default nomarchy.terminal = kitty; SUPER+Return, doctor, calendar,
  what-changed use kitty --class=com.nomarchy.*
- Drop install-time glxinfo probe and mesa-demos on the installer
- Docs/REQUIREMENTS no longer list OpenGL 4.3 as a terminal floor

Verified: V0 flake check; option-docs; installer-safety; template HM has
kitty, no ghostty; menu/calendar emit classed kitty launches.
This commit is contained in:
2026-07-15 09:51:27 +01:00
parent 1e648b6c49
commit 545e40f4d9
32 changed files with 151 additions and 299 deletions

View File

@@ -1,26 +1,13 @@
# Kitty — fallback terminal when Ghostty cannot run (OpenGL < 4.3 on
# older GPUs, e.g. Intel HD 4000). Themed from the same theme-state.json
# as Ghostty so a machine that needs the fallback still looks like
# Nomarchy. Enabled when nomarchy.terminal is "kitty" (installer sets
# that after a GL probe) or when nomarchy.kitty.enable is forced on.
# Kitty — Nomarchy's only terminal, themed from theme-state.json.
# Colors, fonts and the full 16-color ANSI palette are baked from the
# JSON at eval time (same contract Ghostty used to have). Always
# installed: SUPER+Return, SUPER+E, doctor, calendar, and $TERMINAL
# all depend on it.
{ config, lib, ... }:
let
t = config.nomarchy.theme;
c = t.colors;
# Default terminal may be a bare name ("kitty") or a path; match the
# basename so settings.terminal = "kitty" and nomarchy.terminal =
# "${pkgs.kitty}/bin/kitty" both light this module.
terminalIsKitty =
let
term = config.nomarchy.terminal;
base = lib.last (lib.splitString "/" term);
in
base == "kitty" || lib.hasPrefix "kitty " term;
enabled = config.nomarchy.kitty.enable || terminalIsKitty;
# Kitty colorN = ANSI 015 from the theme palette.
colorSettings = lib.listToAttrs (
lib.imap0 (i: color: {
name = "color${toString i}";
@@ -29,35 +16,37 @@ let
);
in
{
config = lib.mkIf enabled {
programs.kitty = {
enable = true;
shellIntegration.enableBashIntegration = true;
shellIntegration.enableZshIntegration = true;
# Kitty is ALWAYS installed. `nomarchy.kitty.enable` gates only whether
# Nomarchy's theming/config is applied — a user can keep kitty but drop
# our config; they cannot remove kitty itself without breaking the
# desktop's load-bearing classed windows.
programs.kitty = {
enable = true;
shellIntegration.enableBashIntegration = true;
shellIntegration.enableZshIntegration = true;
font = {
name = t.fonts.mono;
size = t.fonts.size;
};
settings = {
background = c.base;
foreground = c.text;
cursor = c.accent;
cursor_text_color = c.base;
selection_background = c.overlay;
selection_foreground = c.text;
url_color = c.accent;
active_border_color = c.accent;
inactive_border_color = c.surface;
# Match Ghostty's padding / opacity so the two terminals feel
# like the same product when a machine falls back.
background_opacity = t.ui.terminalOpacity;
window_padding_width = lib.mkDefault 12;
confirm_os_window_close = lib.mkDefault 0;
enable_audio_bell = lib.mkDefault false;
wayland_titlebar_color = lib.mkDefault "background";
} // colorSettings;
font = lib.mkIf config.nomarchy.kitty.enable {
name = t.fonts.mono;
size = t.fonts.size;
};
settings = lib.mkIf config.nomarchy.kitty.enable ({
background = c.base;
foreground = c.text;
cursor = c.accent;
cursor_text_color = c.base;
selection_background = c.overlay;
selection_foreground = c.text;
url_color = c.accent;
active_border_color = c.accent;
inactive_border_color = c.surface;
background_opacity = t.ui.terminalOpacity;
window_padding_width = lib.mkDefault 12;
confirm_os_window_close = lib.mkDefault 0;
enable_audio_bell = lib.mkDefault false;
wayland_titlebar_color = lib.mkDefault "background";
# Fresh windows for doctor/calendar --class launches (not one shared instance).
single_instance = lib.mkDefault false;
} // colorSettings);
};
}