You don’t need a graphical interface to search the web. Googler is a powerful command-line tool that allows you to search Google, Google News, and specific websites directly from your Linux terminal. Below, you will find a complete guide on how to install Googler on Ubuntu and Arch Linux, along with essential commands to boost your productivity.
What is Googler?
Let’s suppose you are working in the terminal (change permissions, edit configuration files, etc.) and, to save time, you can search directly on Google without leaving the command line. The application for Google searching in the command-line is called Googler.
It can be used as a standalone application, or in combination with a text-based web browser (example: Links). Googler is developed in Python and can be found in GitHub.
Prerequisites of Googler: it requires a version of Python greater than 3.3. To check which version of Python you have installed run the command:
python3 –version
How to Install Googler
Installing Google in Arch Linux
As usual, Arch Linux does not disappoint anyone and allows Googler to be installed from AUR:
yaourt -S googler
or
pacaur -S googler
Get to know more about the system with our Arch Linux terminology guide.
Installing Googler in Ubuntu
Unfortunately, Googler is not yet available in Ubuntu warehouses, but it can be installed directly from GitHub by following the steps below.
• Install Git (if you do not already have it installed):
sudo apt-get install git
• Clone the repository and install. Run the following commands:
cd /tmp
git clone https://github.com/jarun/googler.git
cd googler
sudo make installcd auto-completion/bash/
cd auto-completion/bash/
sudo cp googler-completion.bash /etc/bash_completion.d/
Curious about Ubuntu? Read how to increase the performance of an Ubuntu system.
How to use Googler? Essential Commands
It is extremely simple to use. Run the googler command followed by your query.
Basic search in Googler
googler what-we-want-to-look for
Tip: If you write the number attached to each search result and press ENTER, the link opens in the default browser in the system.
Google News Search
To search specifically in News, use the –news or -N flag:
googler –news your_query
googler -N your_query
Googler search on a particular website
To search within a specific domain (like searching specifically on mvps.net):
googler -w query field
googler -w mvps.net linux
Limit the number of results
If you think there are too many results (the first 10 are displayed), you can limit their number using the –count=N parameter, where N represents the desired number of displayed results:
googler –count=N query
View the Googler manual
To see all the options Googler allows, just look at its manual using the famous man command:
man googler
