sed Tip: Delete All Blank White Spaces

I have a text file as follows: foo bar foobar How can I delete all leading and/or trailing blank spaces, tab from each line using sed command?   You can use sed command to delete…

Mac OS X: Wake Up Servers Using Wake-on-LAN ( WOL ) Command Utility

I know how to send WOL command using Linux or FreeBSD wake command. But, how do I send Wake on LAN (WOL) frames to hosts on a local Ethernet network using Apple OS X Unix…

Unix / Linux: Remove duplicate lines from a text file using awk or perl

I have a text file with exact duplicates of lines. I need to remove all those duplicates lines and preserves the order too on Linux or Unix-like system. How do I delete duplicate lines from…

Unix / Linux: Remove duplicate lines from a text file using awk or perl

I have a text file with exact duplicates of lines. I need to remove all those duplicates lines and preserves the order too on Linux or Unix-like system. How do I delete duplicate lines from…