diff options
| author | Craig Jennings <c@cjennings.net> | 2026-06-25 22:45:22 -0400 |
|---|---|---|
| committer | Craig Jennings <c@cjennings.net> | 2026-06-25 22:45:22 -0400 |
| commit | cbd38d881d723f04aab748740977916707f24034 (patch) | |
| tree | ede1ff4d56489ce6acf4f188a2f091b4cb4dfa0c /modules/eshell-config.el | |
| parent | 0b74f6241a2d0736572f1e0653c1f96e89756f56 (diff) | |
| download | dotemacs-cbd38d881d723f04aab748740977916707f24034.tar.gz dotemacs-cbd38d881d723f04aab748740977916707f24034.zip | |
refactor(term): F12 opens eshell-through-EAT, retire eshell-toggle and xterm-color
Point the F12 dock-and-remember toggle at eshell instead of a standalone EAT zsh shell, so the primary terminal is eshell running through EAT (eat-eshell-mode): elisp functions as commands, TRAMP transparency, and EAT rendering visual commands. Drop the eshell-toggle package and its C-<f12> binding, since F12 covers it now. Drop xterm-color from eshell, since EAT handles ANSI color natively and its TERM=xterm-256color fought EAT's own. The toggle's buffer predicate now matches eshell-mode; the toggle tests and fixture are updated.
Diffstat (limited to 'modules/eshell-config.el')
| -rw-r--r-- | modules/eshell-config.el | 34 |
1 files changed, 5 insertions, 29 deletions
diff --git a/modules/eshell-config.el b/modules/eshell-config.el index 33b900af6..ac583cf70 100644 --- a/modules/eshell-config.el +++ b/modules/eshell-config.el @@ -188,35 +188,11 @@ pairs where COMMAND is the `cd' string `eshell/alias' should run." (require 'eat) (eat-eshell-mode 1)) -(use-package eshell-toggle - :custom - (eshell-toggle-size-fraction 2) - (eshell-toggle-run-command nil) - (eshell-toggle-init-function #'eshell-toggle-init-eshell) - :bind - ("C-<f12>" . eshell-toggle)) - -(use-package xterm-color - :after eshell - ;; Two hooks. eshell-before-prompt is the real hook name; use-package appends - ;; "-hook", so writing eshell-before-prompt-hook here registered on a - ;; nonexistent eshell-before-prompt-hook-hook and never ran. The eshell-mode - ;; hook scopes TERM=xterm-256color to eshell-spawned processes only (a global - ;; setenv would leak it to every start-process regardless of terminal). - :hook - ((eshell-before-prompt . (lambda () - (setq xterm-color-preserve-properties t))) - (eshell-mode . (lambda () - (setq-local process-environment - (cons "TERM=xterm-256color" - process-environment))))) - :config - ;; Wire xterm-color into eshell's output pipeline (per its README): install - ;; the filter and drop eshell's own ANSI handler. Without this the escapes are - ;; never interpreted and TERM=xterm-256color only leaks raw codes. - (add-to-list 'eshell-preoutput-filter-functions 'xterm-color-filter) - (setq eshell-output-filter-functions - (remove 'eshell-handle-ansi-color eshell-output-filter-functions))) +;; eshell-toggle and xterm-color are retired. F12 opens eshell now (the +;; dock-and-remember toggle in eat-config.el), and eat-eshell-mode renders +;; eshell's output through EAT, which handles ANSI color natively -- so +;; xterm-color's filter and its TERM=xterm-256color override are redundant and +;; would fight EAT's own TERM=eat-truecolor. (use-package eshell-syntax-highlighting :after esh-mode |
