aboutsummaryrefslogtreecommitdiff
path: root/sx-search.el
diff options
context:
space:
mode:
authorArtur Malabarba <bruce.connor.am@gmail.com>2015-02-14 15:48:53 -0200
committerArtur Malabarba <bruce.connor.am@gmail.com>2015-02-14 15:48:53 -0200
commit9140a717b13b2e4919164b249f6d4b83b47ba53e (patch)
tree6432765345b58b414ae3d4769f8aabb9e794ab55 /sx-search.el
parentcb29144eb54eb8541f469995a13909ec0bdb1c1d (diff)
Add an sx-tag-meta property to tags.
Diffstat (limited to 'sx-search.el')
-rw-r--r--sx-search.el12
1 files changed, 9 insertions, 3 deletions
diff --git a/sx-search.el b/sx-search.el
index b33efff..b245cbe 100644
--- a/sx-search.el
+++ b/sx-search.el
@@ -126,9 +126,15 @@ prefix argument, the user is asked for everything."
(let ((tag (save-excursion
(when pos (goto-char pos))
(or (get-text-property (point) 'sx-tag)
- (thing-at-point 'symbol)))))
- (sx-search (or sx-question-list--site
- (sx-assoc-let sx-question-mode--data .site_par))
+ (thing-at-point 'symbol))))
+ (meta (save-excursion
+ (when pos (goto-char pos))
+ (get-text-property (point) 'sx-tag-meta)))
+ (site (replace-regexp-in-string
+ (rx string-start "meta.") ""
+ (or sx-question-list--site
+ (sx-assoc-let sx-question-mode--data .site_par)))))
+ (sx-search (concat (when meta "meta.") site)
nil tag)))
(provide 'sx-search)