diff options
author | JSDurand <mmemmew@gmail.com> | 2021-03-06 14:56:30 +0800 |
---|---|---|
committer | JSDurand <mmemmew@gmail.com> | 2021-03-06 14:56:30 +0800 |
commit | f9f272c614f75878d012f5d655393cc73e319321 (patch) | |
tree | d43d0bd63a4e3a1536d61d7d7601b0afb5c4a83c | |
parent | 8bb6e3e47b86568309e0607428de06708ba2ced7 (diff) |
Use searx as the default search engine.
This seems to be both faster and to produce more results.
-rw-r--r-- | eww-conf.el | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/eww-conf.el b/eww-conf.el index 8b8a379..d10b3a5 100644 --- a/eww-conf.el +++ b/eww-conf.el @@ -13,7 +13,22 @@ (setq eww-bookmarks-directory load-file-directory) -(setq eww-search-prefix "https://duckduckgo.com/lite/?q=") +(setq eww-search-prefix "https://searx.lukesmith.xyz/search?q=") + +(define-key eww-mode-map (vector 'C-tab) + #'durand-eww-goto-search-result) + +;;;###autoload +(defun durand-eww-goto-search-result () + "Go to the search results on a search page. +Otherwise, just go to the beginning of the page." + (interactive) + (save-match-data + (cond + ((string-match-p "searx\\." (plist-get eww-data :url)) + (re-search-forward "search results")) + ((goto-char (point-min))))) + (recenter 0)) (provide 'eww-conf) |