dotfiles/private_dot_config
Anton Volnuhin af52fcf7a3 tide: ask the terminal for its background instead of reading config files
Over ssh the light prompt segments came out lighter than the background
instead of darker. __tide_terminal_background_color learned the
background by reading <appearance>-theme.auto.conf, which on a remote
host belongs to *that* machine: devry pins theme-mode to dark, so
apply-theme-mode.sh writes the dark theme into all three slots there,
including light-theme.auto.conf. Asked for a light background it found
#212121, correctly refused it as contradicting the appearance, ran out of
files and left the caller on its plain-white fallback -- and a segment
derived from white sits above a #EBE8E4 background rather than below it.
Dark was unaffected because that path never recomputes the palette.

Ask the terminal instead, with an OSC 11 query: it is the one source that
describes the window this shell is actually displayed in, whichever
machine the shell runs on. The config files stay as the fallback, where
they are still right, and the static white behind them.

The query costs one 0.2s-bounded read per appearance change, restores the
terminal settings before it can fail, and steps aside under tmux and
screen, which need the query wrapped and each want it wrapped
differently.

Covered by a new live pty scenario that reproduces the ssh case exactly --
config files all dark, terminal reporting light -- which fails on the
previous ordering, plus unit tests for the reply parser and the fallback
chain.
2026-08-06 16:08:40 +03:00
..
atuin Small combined changes 2026-07-27 20:23:32 +03:00
bat default theme for bat 2024-05-17 23:22:43 +03:00
helix force true color in helix 2024-09-01 00:09:40 +03:00
kitty tide: ask the terminal for its background instead of reading config files 2026-08-06 16:08:40 +03:00
nvim clipboard fixes for tmux and nvim 2026-04-09 02:21:29 +03:00
opencode opencode: fix invalid config and externalize the bailian key 2026-08-06 02:53:27 +03:00
private_fish tide: ask the terminal for its background instead of reading config files 2026-08-06 16:08:40 +03:00
private_karabiner/private_assets/private_complex_modifications restructure repo, fix fish config, remove vendored repos 2026-03-02 19:11:10 +03:00
scripts Modernize Neovim treesitter bootstrap 2026-03-31 01:45:02 +03:00
wezterm kitty: color terminal tabs by ssh/mosh host 2026-05-19 23:08:32 +03:00
karabiner.edn Preserve local Karabiner and Pi preferences 2026-07-27 22:33:34 +03:00