Remove windmove config

Add shortcut to home-manager flake (in the same style as nixos flake shortcut)
This commit is contained in:
Evie Litherland-Smith 2024-05-11 17:08:21 +01:00
parent 55f2733e84
commit ed16385ea9

22
init.el
View file

@ -332,6 +332,16 @@
(warn (concat flake " not found")))))
(keymap-global-set "C-c w n" #'my/open-nixos-flake)
;; home-manager flake shortcut
(defun my/open-home-manager-flake ()
"Open home-manager config flake."
(interactive)
(let ((flake "~/.config/home-manager/flake.nix"))
(if (file-exists-p flake)
(find-file flake)
(warn (concat flake " not found")))))
(keymap-global-set "C-c w h" #'my/open-home-manager-flake)
;; Tempel template file shortcut
(defun my/open-template-file ()
"Open `tempel' template file."
@ -546,18 +556,6 @@ Uses `my/projects-directory' to find correct directory"
(setq split-height-threshold nil
split-width-threshold 160)
(use-package windmove
:demand
:config (windmove-mode +1)
:bind (("C-c w k" . windmove-up)
("C-c w K" . windmove-swap-states-up)
("C-c w j" . windmove-down)
("C-c w J" . windmove-swap-states-down)
("C-c w h" . windmove-left)
("C-c w H" . windmove-swap-states-left)
("C-c w l" . windmove-right)
("C-c w L" . windmove-swap-states-right)))
(use-package winner
:demand
:bind (("C-c w u" . winner-undo)