Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quitting an s2ed command leaves the minibuffer backspace binding broken #32

Open
glucas opened this issue Sep 14, 2023 · 0 comments
Open

Comments

@glucas
Copy link

glucas commented Sep 14, 2023

The fix for #26 works great as long as you complete the s3ed command. I've found that if you change your mind and quit (C-g), the backspace binding remains and causes an error for other minibuffer commands.

I commented on #27 with a workaround: I am advising the s3ed commands to handle the quit signal:

(defun my/s3ed-quit-handler (orig &rest args)
  (condition-case nil
      (apply orig args)
    (quit (define-key minibuffer-local-map (kbd "<backspace>") nil))))
(advice-add #'s3ed-find-file :around #'my/s3ed-quit-handler)
(advice-add #'s3ed-save-file :around #'my/s3ed-quit-handler)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant