14

On the overview in gnome-shell, there are two search buttons for Google and Wikipedia. Is it possible to create a similar button for Ask Ubuntu?

1 Answer 1

7

I have found fossfreedom's answer to create a DuckDuckGo search button in gnome-shell to be useful and I have used it as a base to answer this question.

To create a new search provider, copy the google.xml file as a template.

11.10

sudo cp /usr/share/gnome-shell/search_providers/google.xml /usr/share/gnome-shell/search_providers/askubuntu.xml

12.04

sudo cp /usr/share/gnome-shell/open-search-providers/google.xml /usr/share/gnome-shell/open-search-providers/askubuntu.xml

Change the following XML tags in the askubuntu.xml file:

<ShortName>Ask Ubuntu</ShortName>
<Description>Ask Ubuntu Search</Description>
<Url type="text/html" method="GET" template="https://askubuntu.com/?q={searchTerms}"/>

If you have done everything right, you should be seeing the Ask Ubuntu search button in the overview.

enter image description here

3
  • 2
    <Url type="text/html" method="GET" template="http://askubuntu.com/search?q={searchTerms}"/> (Use this url string instead, to make use of the search function! - Curious, no one mentioned it!!)
    – v2r
    Apr 20, 2012 at 20:03
  • @v2r Very good point indeed. Changed the URL as you mentioned. Thanks!
    – jokerdino
    Apr 20, 2012 at 22:29
  • You are welcome jokerdino!
    – v2r
    Apr 22, 2012 at 16:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .