mirror of
https://github.com/jimeh/.emacs.d.git
synced 2026-02-19 13:46:41 +00:00
fix(editor/vertico): resolve race-condition issue with projectile-switch-project
Occasionally right after starting Emacs, it was possible to issue a projectile-switch-project command which ran before my hacky vertico-directory advice had been added. This should ensure the advice gets added earlier.
This commit is contained in:
@@ -60,9 +60,6 @@
|
||||
(define-key map (kbd "DEL") 'backward-delete-char)
|
||||
(define-key map (kbd "M-DEL") 'backward-kill-word)))))
|
||||
|
||||
:config
|
||||
(vertico-directory-mode +1)
|
||||
|
||||
(with-eval-after-load 'projectile
|
||||
;; Hackily disable vertico-directory-mode when completing things for
|
||||
;; projectile. This avoids breaking projectile-switch-project command.
|
||||
@@ -76,7 +73,10 @@
|
||||
(apply orig-fun args)))
|
||||
|
||||
(advice-add 'projectile-completing-read :around
|
||||
'siren-vertico-projectile-completing-read)))
|
||||
'siren-vertico-projectile-completing-read))
|
||||
|
||||
:config
|
||||
(vertico-directory-mode +1))
|
||||
|
||||
(provide 'siren-vertico)
|
||||
;;; siren-vertico.el ends here
|
||||
|
||||
Reference in New Issue
Block a user