branch: externals/gtags-mode
commit 17d4316d86f0be1e5a3fe71910a11e014798cc36
Merge: 333b0ac032 86a846e3b5
Author: Jimmy Aguilar Mena <kratsbinov...@gmail.com>
Commit: Jimmy Aguilar Mena <kratsbinov...@gmail.com>

    Merge remote-tracking branch 'aagon/completion_libraries'
---
 gtags-mode.el | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/gtags-mode.el b/gtags-mode.el
index 89a7127a7e..5e5d589329 100644
--- a/gtags-mode.el
+++ b/gtags-mode.el
@@ -261,9 +261,16 @@ completions usually from the cache when possible."
     (error "Calling `gtags-mode--list-completions' with no gtags-mode--plist"))
    ((and (stringp prefix)
         (not (string-match-p "\\`[ \t\n\r-]*\\'" prefix)) ;; not match empty 
or only -
-        (gtags-mode--exec-sync "--ignore-case" "--completion" prefix)))
+        (gtags-mode--exec-sync "--directory"
+                               (file-local-name
+                                (plist-get (gtags-mode--local-plist 
default-directory) :gtagsroot))
+                               "--ignore-case" "--through" "--completion" 
prefix)))
    ((plist-get gtags-mode--plist :cache))
-   (t (plist-put gtags-mode--plist :cache (gtags-mode--exec-sync 
"--completion"))
+   (t (plist-put gtags-mode--plist :cache
+                (gtags-mode--exec-sync "--directory"
+                                       (file-local-name
+                                        (plist-get (gtags-mode--local-plist 
default-directory) :gtagsroot))
+                                       "--through" "--completion"))
       (plist-get gtags-mode--plist :cache))))
 
 (defun gtags-mode--filter-find-symbol (args symbol creator)

Reply via email to