From b2da3e3b880df26f62fd73eaaa1c155e27e8ac93 Mon Sep 17 00:00:00 2001 From: Benson Chu Date: Sun, 29 Jan 2023 15:56:59 -0600 Subject: [PATCH] Fix for exwm issue searching --- config-exwm.org | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/config-exwm.org b/config-exwm.org index d5743cc..c723485 100644 --- a/config-exwm.org +++ b/config-exwm.org @@ -190,3 +190,24 @@ (shell-command "emacs & disown") (kill-emacs)))) #+end_src +* exwm fix +#+begin_src emacs-lisp + (defun my/exwm-input--fake-last-command () + "Fool some packages into thinking there is a change in the buffer." + (setq last-command #'exwm-input--noop) + (condition-case hook-error + (progn + (run-hooks 'pre-command-hook) + (run-hooks 'post-command-hook)) + ((error) + (exwm--log "Error occurred while running command hooks: %s\n\nBacktrace:\n\n%s" + hook-error + (with-temp-buffer + (setq-local standard-output (current-buffer)) + (backtrace) + (buffer-string)))))) + + (advice-add #'exwm-input--fake-last-command + :override + #'my/exwm-input--fake-last-command) +#+end_src