Add custom search providers to Gnome Shell

/
0 Comments
If you are using Gnome shell on your Linux system then initially you will find only 2 search providers in your Gnome Shell and those are Google and Wikipedia.

Now what if you want to add few other search provider like Bing or even you want to add search to few other amazing sites like http://www.wolframalpha.com/ ? (Don't know what is Wolframalpha? click here to see it's Wikipedia page)

In this post I will add search button for Wolframalpha in my Gnome Shell. You can add search button for other sites like Bing using similar procedure.

Follow these steps:

1) You can find xml configuration files for gnome shell search providers in following directory.

/usr/share/gnome-shell/search_providers 

In this directory you can initially find 2 xml files. One is for Google and other is for Wikipedia.



2) Now we will copy the file google.xml with the name wolframalpha.xml and then we will edit this new file:

For that fire following command in terminal:

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

3) Now we will edit wolframalpha a little:
Fire following command to open wolframalpha.xml in gedit.

sudo gedit /usr/share/gnome-shell/search_providers/wolframalpha.xml

4) In the opened file find following line:
<ShortName>Google</ShortName>

and replace it with

<ShortName>Wolframalpha</ShortName>.

This is the name which will appear on your gnome shell.

Now same way change the value description  tag accordingly. Initially it would be "google search". We can make it "Wolframalpha search".

Now comes the most important URL tag. In template property of URL tag you will find
http://www.google.com/search?q={searchTerms}  

Replace it with
http://www.wolframalpha.com/input/?i={searchTerms}

( Note: for bing set template property with http://www.bing.com/search?q={searchTerms} )

Save the file close gedit and restart gnome shell to see the changes. :)




You may also like

Popular Posts