Skip to content

Commit

Permalink
counsel.el (counsel-compile): don't squash default-directory
Browse files Browse the repository at this point in the history
We may not have defined a blddir, especially if the user has manually
entered the make invocation. If blddir is nil then just keep
default-directory as is.
  • Loading branch information
stsquad committed Apr 17, 2019
1 parent 0eae456 commit 26a6322
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion counsel.el
Expand Up @@ -5414,7 +5414,7 @@ specified by the `blddir' property."
(when (get-char-property 0 'cmd cmd)
(setq cmd (substring-no-properties
cmd 0 (next-single-property-change 0 'cmd cmd))))
(let ((default-directory blddir)
(let ((default-directory (or blddir default-directory))
(compilation-environment bldenv))
;; No need to specify `:history' because of this hook.
(add-hook 'compilation-start-hook #'counsel-compile--update-history)
Expand Down

0 comments on commit 26a6322

Please sign in to comment.