This repository has been archived on 2024-10-22. You can view files and clone it, but cannot push or open issues or pull requests.
spacemacs/layers/+web-services/search-engine/README.org
2019-05-15 21:08:21 +03:00

74 lines
2.1 KiB
Org Mode
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#+TITLE: Search Engine layer
#+TAGS: layer|web service
[[file:img/searchengine.jpg]]
* Table of Contents :TOC_5_gh:noexport:
- [[#description][Description]]
- [[#features][Features:]]
- [[#supported-search-engines][Supported search engines]]
- [[#install][Install]]
- [[#key-bindings][Key bindings]]
- [[#customize-it][Customize it!]]
* Description
This layer adds support for the [[https://github.com/hrs/engine-mode][Search Engine]] package.
** Features:
- Browser search integration
* Supported search engines
- Amazon
- Bing
- Duck Duck Go
- Ecosia
- Google
- Google Images
- GitHub
- Google Maps
- Twitter
- Project Gutenberg
- YouTube
- Stack Overflow
- Spacemacs Issues
- Spacemacs Pull Requests
- Wikipedia
- Wolfram Alpha
* Install
To use this configuration layer, add it to your =~/.spacemacs=. You will need to
add =search-engine= to the existing =dotspacemacs-configuration-layers= list in this
file.
* Key bindings
| Evil | Holy | Command |
|-----------+---------+-------------------------------------------|
| ~SPC a /~ | ~C-c /~ | Summon a Helm buffer to select any engine |
* Customize it!
If youd rather have emacs use chrome, or firefox or any other thing (=eww=) you
can have that customization. For example for google chrome you can put this in
your =dotspacemacs/user-config=:
#+BEGIN_SRC emacs-lisp
(setq browse-url-browser-function 'browse-url-generic
engine/browser-function 'browse-url-generic
browse-url-generic-program "google-chrome")
#+END_SRC
Also if you want more search engines, just push them (do this in
=dotspacemacs/user-config=)
#+BEGIN_SRC emacs-lisp
(push '(custom1
:name "Custom Search Engine 1"
:url "http://www.domain.com/s/stuff_sutff_remember_to_replace_search_candidate_with_%s")
search-engine-alist)
#+END_SRC
If youd rather not use helm but would want a specific search engine, remember
the function generated is always =engine/search-(the name of the search engine
lower-case and hyphen instead-of-spaces-for-separation)= so you can bind that to
any key binding you want.