Thursday, 19 July, 2007

Google to search man pages

You are in your browser, furiously typing away your latest shell script (to send it to someone else, or to post in forums or at Slashdot). Suddenly, your memory trips you up, and you find yourself wondering "does the 'cut' command use a space or a tab as the default delimiter?". With Google at your service, there is no need to move away from your browser. If you are on firefox, just type 'man cut' in the addressbar; otherwise, google for 'man cut' and use the first result.
Google doubles up as a 'linux command helper' like this whenever we use search queries of the form 'man command'. Add one word to the query anywhere, and we get our good old Google search.
I had been using this method for quite a while. But I was not sure whether it was an intentional feature or it's just that the man pages tend to be the first results. But today, when I tried 'man cut', I landed on the man page. It is hard to imagine that a man page could overshadow common meanings of the words (man and cut). So, it does seem that google treats 'man command' searches specially...
It seems that this is not an officially announced feature - a google search for details about it returned no relevant results. Anyway, it does work. Our beloved man pages are now only a 'new tab' away!

No comments: