branch: externals/urgrep commit 0270e118493466dc120a83fe7b5037303b628b3f Author: Jim Porter <jporterb...@gmail.com> Commit: Jim Porter <jporterb...@gmail.com>
Allow directory for `urgrep' and `urgrep-run-command' to be relative --- urgrep.el | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/urgrep.el b/urgrep.el index 813df7e505..77164fcf91 100644 --- a/urgrep.el +++ b/urgrep.el @@ -1000,7 +1000,8 @@ Type \\[urgrep-set-file-wildcards] to set a wildcard to filter the files searche (let* ((full-query (cons query rest)) (command (apply #'urgrep-command full-query)) (tool (urgrep-get-tool (cadr (cl-member :tool full-query)))) - (default-directory (or directory default-directory))) + (default-directory (if directory (expand-file-name directory) + default-directory))) (urgrep--start command full-query tool))) ;;;###autoload @@ -1015,7 +1016,8 @@ to edit the command before running it." (list (urgrep--read-command (apply #'urgrep-command query)) directory (cadr (cl-member :tool query))))) (let ((tool (urgrep-get-tool tool)) - (default-directory (or directory default-directory))) + (default-directory (if directory (expand-file-name directory) + default-directory))) (urgrep--start command command tool))) ;;;###autoload