about summary refs log tree commit diff
path: root/users/sterni/emacs
diff options
context:
space:
mode:
authorsterni <sternenseemann@systemli.org>2022-05-09T13·43+0200
committerclbot <clbot@tvl.fyi>2022-05-09T13·53+0000
commit952922a0a9e1d1a000dc64b5ecba6bd55de9169d (patch)
treef0bd7887291b74cfde8273e2ae5bd6046197ccd9 /users/sterni/emacs
parent6128f0262e82df30eb24daf8da8c7d08ecb0f7f8 (diff)
feat(sterni/emacs): use evil C-w bindings, but with arrow keys r/4021
hjkl are a huge pain to use with neo layout.

Change-Id: Ic3969c00aa920c4cfea25f5ea16bf38b6bbd5e07
Reviewed-on: https://cl.tvl.fyi/c/depot/+/5541
Reviewed-by: sterni <sternenseemann@systemli.org>
Autosubmit: sterni <sternenseemann@systemli.org>
Tested-by: BuildkiteCI
Diffstat (limited to 'users/sterni/emacs')
-rw-r--r--users/sterni/emacs/init.el11
1 files changed, 5 insertions, 6 deletions
diff --git a/users/sterni/emacs/init.el b/users/sterni/emacs/init.el
index ac235d2d2f20..e04ed724bfdb 100644
--- a/users/sterni/emacs/init.el
+++ b/users/sterni/emacs/init.el
@@ -146,12 +146,11 @@
   (evil-define-key 'normal 'global (kbd "<leader>bk") 'kill-buffer)
   (evil-define-key 'normal 'global (kbd "<leader>bb") 'switch-to-buffer)
   (evil-define-key 'normal 'global (kbd "<leader>bl") 'list-buffers)
-  ;; window management
-  (evil-define-key 'normal 'global (kbd "<leader>wk") 'delete-window)
-  (evil-define-key 'normal 'global (kbd "<leader>wo") 'delete-other-window)
-  (evil-define-key 'normal 'global (kbd "<leader>wh") 'split-window-below)
-  (evil-define-key 'normal 'global (kbd "<leader>wv") 'split-window-right)
-  (evil-define-key 'normal 'global (kbd "<leader>ww") 'other-window)
+  ;; window management: C-w hjkl is annoying in neo
+  (define-key evil-window-map (kbd "<left>") 'evil-window-left)
+  (define-key evil-window-map (kbd "<right>") 'evil-window-right)
+  (define-key evil-window-map (kbd "<up>") 'evil-window-up)
+  (define-key evil-window-map (kbd "<down>") 'evil-window-down)
   ;; emacs
   (evil-define-key 'visual 'global (kbd "<leader>ee") 'eval-region)
   (evil-define-key 'normal 'global (kbd "<leader>ee") 'eval-last-sexp)