Skip to content

Commit

Permalink
Fix "Couldn't find project root" error on +ivy/compile
Browse files Browse the repository at this point in the history
  • Loading branch information
hlissner committed Jun 4, 2021
1 parent 14326d6 commit 883a109
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion modules/completion/ivy/autoload/ivy.el
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,11 @@ If ARG (universal argument), include all files, even hidden or compressed ones."
(defun +ivy/compile ()
"Execute a compile command from the current buffer's directory."
(interactive)
(counsel-compile default-directory))
;; Fix unhelpful 'Couldn't find project root' error
(letf! (defun counsel--compile-root ()
(ignore-errors
(funcall counsel--compile-root)))
(counsel-compile default-directory)))

;;;###autoload
(defun +ivy/project-compile ()
Expand Down

0 comments on commit 883a109

Please sign in to comment.