Category Archives: Networking

Extract a tarball online without local saving

This can be a real saver if you are using an EeePC with very low disk space. Say you want to download a large file but you don’t want to save it locally because you don’t have the necessary disk space. Do a wget -qO – “” | tar zxvf –

Quickly query Wikipedia by using the Linux CLI

Stuck at a CLI prompt in Linux and not sure what Romania is? Use the following command: dig +short txt Subsitute Romania for any other keyword you might want to see a short description of in your command line.

Check your unread GMail e-mails using the Linux command line

All you need to display your latest GMail messages in the command line is this one-liner: curl -u username:password –silent “” | tr -d ‘\n’ | awk -F ‘<entry>’ ‘{for (i=2; i<=NF; i++) {print $i}}’ | sed -n “s/<title>\(.*\)<\/title.*name>\(.*\)<\/name>.*/\2 – \1/p” Substitute username:password with your GMail username and password.

Display the current directory as a webpage in Linux

Do you want to quickly serve a directory to your friends over the web or LAN? There are plenty of applications out there that let you do this, but in Linux all you really need is Python installed.Do a python -m SimpleHTTPServer in the directory you wish to share, then access in your browser.