diff options
author | Vincent Ambo <tazjin@google.com> | 2019-12-16T03·53+0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-12-16T03·53+0000 |
commit | 4897669f501a9718d7e02287aee781aecb156c0f (patch) | |
tree | 45573d1739d27fe3391fc42848597b283fa8bb1d /tools/emacs | |
parent | d4f6c5a399e4202e57de572f7a7193f1537939d9 (diff) | |
parent | d63996c3cb9640b34fa4112d460a060742ade99c (diff) |
merge(PR#12): Switch Emacs terminals over to libvterm r/160
This moves the terminals inside of my Emacs from being `gnome-terminal` instances under EXWM over to [emacs-libvterm](https://github.com/akermu/emacs-libvterm). This incredible package embeds a fully featured terminal emulator (based on `libvterm`) into Emacs with the killer feature of being able to switch a terminal buffer to read-only text mode and use normal Emacs selection commands. This is something I've wanted for a long time and that `ansi-term` etc. just weren't good enough for!
Diffstat (limited to 'tools/emacs')
-rw-r--r-- | tools/emacs/config/init.el | 13 | ||||
-rw-r--r-- | tools/emacs/default.nix | 1 |
2 files changed, 14 insertions, 0 deletions
diff --git a/tools/emacs/config/init.el b/tools/emacs/config/init.el index 7d40813d83f0..06fe707921a4 100644 --- a/tools/emacs/config/init.el +++ b/tools/emacs/config/init.el @@ -73,6 +73,19 @@ (use-package pg) (use-package restclient) +(use-package vterm + :config (progn + (setq vterm-shell "/usr/bin/fish") + (setq vterm-exit-functions + (lambda (&rest _) (kill-buffer (current-buffer)))) + (setq vterm-set-title-functions + (lambda (title) + (rename-buffer + (generate-new-buffer-name + (format "vterm<%s>" + (s-trim-left + (s-chop-prefix "fish" title))))))))) + ;; ;; Packages providing language-specific functionality ;; diff --git a/tools/emacs/default.nix b/tools/emacs/default.nix index 02ffb3660581..742556dd61b9 100644 --- a/tools/emacs/default.nix +++ b/tools/emacs/default.nix @@ -73,6 +73,7 @@ let transient use-package uuidgen + vterm web-mode websocket which-key |