From 8a56a1fc70e6e16de0af5b9edceb01ff00955aa3 Mon Sep 17 00:00:00 2001 From: Jeremy Dormitzer Date: Mon, 8 Mar 2021 14:15:20 -0500 Subject: [PATCH] Add vterm find-file alias and clear scrollback binding --- emacs/.emacs.d/config/init-vterm.el | 5 ++++- zsh/.zshrc | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/emacs/.emacs.d/config/init-vterm.el b/emacs/.emacs.d/config/init-vterm.el index 927850d..708f32f 100644 --- a/emacs/.emacs.d/config/init-vterm.el +++ b/emacs/.emacs.d/config/init-vterm.el @@ -8,7 +8,9 @@ (call-interactively #'vterm))) :config (evil-collection-vterm-setup) - (general-def 'insert vterm-mode-map "C-" #'vterm-send-escape) + (general-def 'insert vterm-mode-map + "C-" #'vterm-send-escape + "C-l" #'vterm-clear-scrollback) ;; Add a hook when vterm changes the directory (defvar vterm-directory-change-hook nil "Hooks to be run after vterm changes the directory") @@ -26,6 +28,7 @@ (vterm-environment '("TYPEWRITTEN_CURSOR=terminal")) (vterm-ignore-blink-cursor t) (vterm-eval-cmds '(("find-file" find-file) + ("ff" find-file) ("message" message) ("vterm-clear-scrollback" vterm-clear-scrollback) ("man" man) diff --git a/zsh/.zshrc b/zsh/.zshrc index 1ea1601..569a78e 100644 --- a/zsh/.zshrc +++ b/zsh/.zshrc @@ -142,6 +142,7 @@ if [[ "$INSIDE_EMACS" = 'vterm' ]]; then alias clear='vterm_printf "51;Evterm-clear-scrollback";tput clear' alias man='vterm_cmd man' alias ediff='vterm_cmd ediff' + alias ff='vterm_cmd find-file' fi # This is to change the title of the buffer based on information provided by the