mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-07 21:29:13 +00:00
Improve Semantic Search Buffer Names in Emacs
- Allow multiple semantic searches buffers to exist simultaneously - Uniquify semantic search buffer namew - Add query and search-type to semantic search buffer name for easier disambiguration, search and find appropriate
This commit is contained in:
@@ -103,7 +103,7 @@
|
|||||||
(let* ((default-type (semantic-search--buffer-name-to-search-type (buffer-name)))
|
(let* ((default-type (semantic-search--buffer-name-to-search-type (buffer-name)))
|
||||||
(search-type (completing-read "Type: " '("notes" "ledger" "music" "image") nil t default-type))
|
(search-type (completing-read "Type: " '("notes" "ledger" "music" "image") nil t default-type))
|
||||||
(url (semantic-search--construct-api-query query search-type))
|
(url (semantic-search--construct-api-query query search-type))
|
||||||
(buff (get-buffer-create "*semantic-search*")))
|
(buff (get-buffer-create (format "*Semantic Search (q:%s t:%s)*" query search-type))))
|
||||||
;; get json response from api
|
;; get json response from api
|
||||||
(with-current-buffer buff
|
(with-current-buffer buff
|
||||||
(let ((inhibit-read-only t))
|
(let ((inhibit-read-only t))
|
||||||
|
|||||||
Reference in New Issue
Block a user