Enable EXWM helpers
This commit is contained in:
parent
e855eeca3d
commit
2bd9910080
19
init.org
19
init.org
|
@ -100,16 +100,19 @@ This needs to be before =boon=/=exwm=, or you get a "failed to define function i
|
|||
([?\s-w] . consult-buffer)
|
||||
([?\s-v] . exwm-input-toggle-keyboard)))
|
||||
#+END_SRC
|
||||
|
||||
Use window title for buffer names.
|
||||
#+BEGIN_SRC emacs-lisp :load no
|
||||
(require 'exwm)
|
||||
(add-hook 'exwm-update-title-hook
|
||||
(lambda ()
|
||||
(exwm-workspace-rename-buffer exwm-title)))
|
||||
(add-hook 'exwm-update-title-hook (lambda () (exwm-workspace-rename-buffer exwm-title)))
|
||||
(exwm-enable)
|
||||
#+END_SRC
|
||||
|
||||
** Helpers
|
||||
:PROPERTIES:
|
||||
:literate-load: yes
|
||||
:header-args: :load yes :tangle yes
|
||||
:END:
|
||||
A less repetitive way to start processes. Also enables Boon in the process buffer, so I can easy navigate it, copy text in it, or switch away from it.
|
||||
#+BEGIN_SRC emacs-lisp :load no
|
||||
(defun my-start-process (program &optional name &rest args)
|
||||
|
@ -122,7 +125,7 @@ A less repetitive way to start processes. Also enables Boon in the process buffe
|
|||
#+END_SRC
|
||||
|
||||
This is useful even without EXWM - switching does not work (...yet?), but I can launch apps via Hydra, and the output goes into the familiar environment of an Emacs buffer.
|
||||
#+BEGIN_SRC emacs-lisp :load no
|
||||
#+BEGIN_SRC emacs-lisp
|
||||
(defun my-start-app-or-switch (program &optional class-re title-re name &rest args)
|
||||
"Switch to EXWM buffer matching CLASS-RE or TITLE-RE, or run PROGRAM with ARGS.
|
||||
NAME is the name of the process and its buffer."
|
||||
|
@ -142,8 +145,12 @@ NAME is the name of the process and its buffer."
|
|||
(apply #'my-start-process program name args))))
|
||||
#+END_SRC
|
||||
|
||||
** Startup programs
|
||||
#+BEGIN_SRC emacs-lisp :load no
|
||||
** Startup programs :disabled:
|
||||
:PROPERTIES:
|
||||
:literate-load: no
|
||||
:tangle: no
|
||||
:END:
|
||||
#+BEGIN_SRC emacs-lisp
|
||||
(my-start-process (expand-file-name "~/bin/kmonad") "kmonad" (expand-file-name "~/kmonad-tvs.kbd"))
|
||||
(my-start-process (expand-file-name "~/bin/kmonad") "kmonad" (expand-file-name "~/kmonad-legion.kbd"))
|
||||
(my-start-process "transmission-gtk")
|
||||
|
|
Loading…
Reference in New Issue