Include buffer tags in global tags completion

* lisp/org.el: (org-global-tags-completion-table): Return all tags,
  including tags in the buffer.

This fixes a bug that caused buffer tags to be excluded if user
configured tags either via `org-tag-alist' or the #+TAGS keyword.
This commit is contained in:
Matt Lundin 2018-03-19 09:53:15 -05:00 committed by Bastien
parent b0cca9656d
commit 393b98ae8e
1 changed files with 5 additions and 4 deletions

View File

@ -14331,10 +14331,11 @@ instead of the agenda files."
(mapcar
(lambda (file)
(set-buffer (find-file-noselect file))
(mapcar (lambda (x)
(and (stringp (car-safe x))
(list (car-safe x))))
(or org-current-tag-alist (org-get-buffer-tags))))
(append (org-get-buffer-tags)
(mapcar (lambda (x)
(and (stringp (car-safe x))
(list (car-safe x))))
org-current-tag-alist)))
(if (car-safe files) files
(org-agenda-files))))))))