{"id":12483,"date":"2019-03-27T03:18:52","date_gmt":"2019-03-27T03:18:52","guid":{"rendered":"http:\/\/www.appservgrid.com\/paw92\/?p=12483"},"modified":"2019-03-27T03:18:52","modified_gmt":"2019-03-27T03:18:52","slug":"googler-a-command-line-tool-to-do-google-search-from-linux-terminal","status":"publish","type":"post","link":"https:\/\/www.appservgrid.com\/paw92\/index.php\/2019\/03\/27\/googler-a-command-line-tool-to-do-google-search-from-linux-terminal\/","title":{"rendered":"Googler: A Command Line Tool to Do \u2018Google Search\u2019 from Linux Terminal"},"content":{"rendered":"<p>Today,\u00a0<strong>Google<\/strong>\u00a0search is a well known and the most-used search engine on the\u00a0<strong>World Wide Web<\/strong>\u00a0(<strong>WWW<\/strong>), if you want to gather information from millions of servers on the Internet, then it is the number one and most reliable tool for that purpose plus much more.<\/p>\n<p>Many people around the world mainly use Google search via a graphical web browser interface. However, command line geeks who are always glued to the terminal for their day-to-day system related tasks, face difficulties in accessing Google search from command-line, this is where\u00a0<strong>Googler<\/strong>\u00a0comes in handy.<\/p>\n<p><strong>Read Also<\/strong>:\u00a0<a href=\"https:\/\/www.tecmint.com\/wikipedia-commandline-tool\/\" target=\"_blank\" rel=\"noopener\">Wikit \u2013 A Command Line Tool to Search Wikipedia in Linux<\/a><\/p>\n<p><strong>Googler<\/strong>\u00a0is a powerful, feature-rich and Python-based command line tool for accessing Google (Web &amp; News) and Google Site Search within the Linux terminal.<\/p>\n<p><strong>Note<\/strong>:\u00a0<strong>Googler<\/strong>\u00a0is not in any way associated to\u00a0<strong>Google<\/strong>.<\/p>\n<h4>How Does Googler Works?<\/h4>\n<p>It provides an interface from the command line to Google search and displays results inform of title, URL and abstract information in pages, with page navigation similar to that on a GUI web browser.<\/p>\n<p>Watch the quick demo of\u00a0<strong>Googler<\/strong>.<\/p>\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-from-Linux-Terminal.gif\"><img decoding=\"async\" class=\"size-full wp-image-24008\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-from-Linux-Terminal.gif\" sizes=\"(max-width: 982px) 100vw, 982px\" srcset=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-from-Linux-Terminal.gif 982w, https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-from-Linux-Terminal-768x415.gif 768w\" alt=\"Google Search from Linux Terminal\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p>Users can integrate it with a\u00a0<a href=\"https:\/\/www.tecmint.com\/command-line-web-browsers\/\" target=\"_blank\" rel=\"noopener\">text-based web browser<\/a>\u00a0and open the result directly in the web browser.<\/p>\n<p>It supports sequential searches in a single instance and importantly, users do not need to master any usage options as the shell completion scripts automatically invokes them.<\/p>\n<h4>Features of Googler<\/h4>\n<ol>\n<li>Offers access to Google Search, Google Site Search, Google News.<\/li>\n<li>It is fast and clean with custom colors and no ads, stray URLs or clutter included.<\/li>\n<\/ol>\n<ol>\n<li>Allows navigation of search result pages from omniprompt.<\/li>\n<li>Supports fetching of number of results in a go, users can start at the nth result.<\/li>\n<li>Users can disable automatic spelling correction and search exact keywords.<\/li>\n<li>Supports limiting of search by attributes such as duration, country\/domain specific search (default:\u00a0<strong>.com<\/strong>), language preference.<\/li>\n<li>Supports Google search keywords in the form\u00a0<strong>filetype:mime<\/strong>,\u00a0<strong>site:somesite.com<\/strong>\u00a0and many others.<\/li>\n<li>Permits non-stop searches: start new searches at omniprompt without exiting.<\/li>\n<li>Supports HTTPS proxy services.<\/li>\n<li>Ships in with a man page which includes examples, shell completion scripts for Bash, Zsh and Fish.<\/li>\n<li>Users can optionally open first search result in a web browser.<\/li>\n<\/ol>\n<h3>How To Install Googler in Linux<\/h3>\n<p>Users of\u00a0<strong>Ubuntu Linux<\/strong>\u00a0and its derivatives such as\u00a0<strong>Linux Mint<\/strong>,\u00a0<strong>Xubuntu<\/strong>\u00a0can install it via this PPA by executing the commands below:<\/p>\n<pre>$ sudo add-apt-repository ppa:twodopeshaggy\/jarun\r\n$ sudo apt-get update\r\n$ sudo apt-get install googler\r\n<\/pre>\n<p><strong>Important<\/strong>: If in case above installation instructions fails to install Googler, then you need to install it from source using latest version as shown.<\/p>\n<p>Other distributions can install Googler from source using following instructions.<\/p>\n<p>First download the\u00a0<a href=\"https:\/\/github.com\/jarun\/googler\/releases\/latest\" target=\"_blank\" rel=\"nofollow noopener\">latest version of Googler<\/a>\u00a0(at the time writing the latest version is\u00a0<strong>v2.9<\/strong>).<\/p>\n<pre>$ cd Downloads\r\n$ wget -c https:\/\/github.com\/jarun\/googler\/archive\/v2.9.tar.gz\r\n$ tar -xvf  v2.9.tar.gz\r\n$ cd  googler-2.9\r\n$ sudo make install \r\n$ cd auto-completion\/bash\/\r\n$ sudo cp googler-completion.bash  \/etc\/bash_completion.d\/\r\n<\/pre>\n<h3>How to Use Googler in Linux Terminal<\/h3>\n<p>The following are some examples showing how Googler works in Linux, the basic command below will show information about\u00a0<code>tecmint.com<\/code>:<\/p>\n<pre>$ googler tecmint.com\r\n<\/pre>\n<div id=\"attachment_24001\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Search-Google-from-Linux-Commandline.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-24001\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Search-Google-from-Linux-Commandline.png\" sizes=\"auto, (max-width: 884px) 100vw, 884px\" srcset=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Search-Google-from-Linux-Commandline.png 884w, https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Search-Google-from-Linux-Commandline-768x837.png 768w\" alt=\"Search Google from Linux Commandline\" width=\"884\" height=\"963\" aria-describedby=\"caption-attachment-24001\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-24001\" class=\"wp-caption-text\">Search Google from Linux Commandline<\/p>\n<\/div>\n<p>At the end of the search result page, you can view the\u00a0<strong>omniprompt<\/strong>\u00a0help page by entering the\u00a0<code>\u201c?\u201d<\/code>\u00a0character and pressing\u00a0<strong>Enter<\/strong>. Each key has a detailed functionality description alongside it.<\/p>\n<div id=\"attachment_24002\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-Options.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-24002\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-Options.png\" sizes=\"auto, (max-width: 884px) 100vw, 884px\" srcset=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-Options.png 884w, https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-Options-768x500.png 768w\" alt=\"Google Search Options\" width=\"884\" height=\"575\" aria-describedby=\"caption-attachment-24002\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-24002\" class=\"wp-caption-text\">Google Search Options<\/p>\n<\/div>\n<p>In the example, we will search for the quoted words (<strong>Linux command line tricks<\/strong>) on\u00a0<code>tecmint.com<\/code>.<\/p>\n<pre>$ googler -n 8 -w tecmint.com \\\"<strong>Linux command line tricks<\/strong>\\\"\r\n<\/pre>\n<p>where the options:<\/p>\n<ol>\n<li><code>-n<\/code>\u00a0num \u2013 tells googler to display at most\u00a0<strong>8<\/strong>\u00a0results per a page (default is\u00a0<strong>10<\/strong>).<\/li>\n<li><code>-w<\/code>\u00a0\u2013 enables Google\u00a0<strong>site(tecmint.com)<\/strong>\u00a0search.<\/li>\n<\/ol>\n<div id=\"attachment_24003\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Site-Search.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-24003\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Site-Search.png\" sizes=\"auto, (max-width: 882px) 100vw, 882px\" srcset=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Site-Search.png 882w, https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Site-Search-768x688.png 768w\" alt=\"Google Site Search Results\" width=\"882\" height=\"790\" aria-describedby=\"caption-attachment-24003\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-24003\" class=\"wp-caption-text\">Google Site Search Results<\/p>\n<\/div>\n<p>You can as well display results of latest news concerning Linux from the Google search news section by using the\u00a0<code>-N<\/code>\u00a0switch as follows:<\/p>\n<pre>$ googler -N Linux \r\n<\/pre>\n<div id=\"attachment_24004\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Search-Linux-News.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-24004\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Search-Linux-News.png\" sizes=\"auto, (max-width: 885px) 100vw, 885px\" srcset=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Search-Linux-News.png 885w, https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Search-Linux-News-768x864.png 768w\" alt=\"Search Linux News from Commandline\" width=\"885\" height=\"996\" aria-describedby=\"caption-attachment-24004\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-24004\" class=\"wp-caption-text\">Search Linux News from Commandline<\/p>\n<\/div>\n<p>Set an alias to get four results showing the meaning of a word (<strong>tecmint<\/strong>\u00a0in this case) like so:<\/p>\n<pre>$ alias tecmint='oogler -n 4 tecmint'\r\n$ tecmint \r\n<\/pre>\n<div id=\"attachment_24005\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-for-Keyword.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-24005\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-for-Keyword.png\" sizes=\"auto, (max-width: 884px) 100vw, 884px\" srcset=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-for-Keyword.png 884w, https:\/\/www.tecmint.com\/wp-content\/uploads\/2016\/12\/Google-Search-for-Keyword-768x483.png 768w\" alt=\"Google Search for Keyword\" width=\"884\" height=\"556\" aria-describedby=\"caption-attachment-24005\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-24005\" class=\"wp-caption-text\">Google Search for Keyword<\/p>\n<\/div>\n<p>Visit the\u00a0<a href=\"https:\/\/github.com\/jarun\/googler\" target=\"_blank\" rel=\"nofollow noopener\">Googler Github<\/a>\u00a0repository for more information and usage or view the Googler man page.<\/p>\n<pre>$ man googler \r\n<\/pre>\n<p><strong>Googler<\/strong>\u00a0is a handy tool, it works perfectly and reliably for Linux users who spend most of their time on the terminal and want to search the web from a text-based interface. Remember to share your thoughts about Googler in the comments.<\/p>\n<p><a href=\"https:\/\/www.tecmint.com\/google-commandline-search-terminal\/\" target=\"_blank\" rel=\"noopener\">Source<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today,\u00a0Google\u00a0search is a well known and the most-used search engine on the\u00a0World Wide Web\u00a0(WWW), if you want to gather information from millions of servers on the Internet, then it is the number one and most reliable tool for that purpose plus much more. Many people around the world mainly use Google search via a graphical &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.appservgrid.com\/paw92\/index.php\/2019\/03\/27\/googler-a-command-line-tool-to-do-google-search-from-linux-terminal\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Googler: A Command Line Tool to Do \u2018Google Search\u2019 from Linux Terminal&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-12483","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/12483","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/comments?post=12483"}],"version-history":[{"count":1,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/12483\/revisions"}],"predecessor-version":[{"id":12484,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/12483\/revisions\/12484"}],"wp:attachment":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/media?parent=12483"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/categories?post=12483"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/tags?post=12483"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}