Is it possible to customise the search-engine buttons in gnome-shell?


Is it possible to customise the search-engine buttons in gnome-shell?

Short answer: Yes it is. 😉

Long answer: A while ago I wrote a post about duckduckgo, and I feel like it’s time to revisit it.

First off: Hit the address you see below.

chrome://settings/searchEngines

Which, if you’re using any of the chrome flavors out there, should display something similar as in the picture below.

Setting up a search-engine in chrome.

Setting up a search-engine in chrome.

https://duckduckgo.com/?q=%s+!google

Next up, as in the example posted on !asku, we’re going to create a new file called duckduckgo.xml

gksudo gedit /usr/share/gnome-shell/open-search-providers/duckduckgo.xml
Path: /usr/share/gnome-shell/open-search-providers/duckduckgo.xml

Path: /usr/share/gnome-shell/open-search-providers/duckduckgo.xml

 … and it will have the following contents.

<OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/">
<ShortName>DuckDuckGo</ShortName>
<Description>Search DuckDuckGo (SSL)</Description>
<InputEncoding>UTF-8</InputEncoding>
<LongName>DuckDuckGo Search (SSL)</LongName>
<Image width="16" height="16">https://duckduckgo.com/favicon.ico</Image>
<Url type="text/html" method="get" template="https://duckduckgo.com/?q={searchTerms}+!google"/>
</OpenSearchDescription>

Now hit:

alt+f2

 … and type or paste in the resulting pop up box the following:

r # followed by an enter.

Happy searching! 😉