Original article by Ankur Aggarwal published on http://flossstuff.wordpress.com/
Wikipedia : One of the most important web portal in geek’s life. Whenever I need to search anything I use two things. First open up the Google and then search for the related wikipedia page. Exploring wikipedia page using shell is possible. Interested fact is that we can do it without even opening the cli browser. We can make wikipedia text query over dns for an ip address. I learned this trick from Ajay Sharma ([email protected]). Thanks to him for teaching me this wonderful trick. Let’s explore how to do it.
We will use ‘dig‘ utility for this purpose. Dig is more popularly known as the DNS lookupUtility. You can find more about it using man pages. Syntax for the text based wikipedia query is : dig +short txt <keyword>.wp.dg.cx . For example if you want to look into the wikipedia page of Linux you need to type something like this : dig +short txt linux.wp.dg.cx . Screenshot of the same is attached below :
For multiple word search having spaces in between them you can use the traditional ‘’ operator. To grasp the wikipedia page of Free Software Foundation (FSF) we need to type dig +short txt free software foundation.wp.dg.cx .
Only problem is its quite limited. I am trying to figure out a way through which we can look up the whole page but I think this much is also quite useful as most of the times we came to know about the product by reading one or two lines only. So play with wikipedia using Shell only
- How to share on linux the output of your shell commands
- An introduction to systemd for CentOS 7
- Linux Games: Sanctum 2
- What goes around comes around: nearly half of DDoS attacked companies are hit twice or more
- How to check if you are vulnerable to shellshock
Find me on Google+