|
|
View a Lord of the Rings timeline easter egg in calendar
Another perfectly valid reason to use cat foo | grep is when you need an alias for quickly getting information out of a log. For example, I have several aliases (I use the AT&T ksh for my shell) that look like:
alias gethist 'cat /var/log/foo.log | grep'This allows me to type only gethist dude to grep 'dude' out of the foo.log log. Saves typing the log path out...Another use is for looking into files that I do not have read permission on (I'm a user consultant here at work and frequently need to look at user and/or system files). Since I do not have sudo (e.g. root) access to the grep command, I often wind up doing sudo cat /root/owned/file | grep foo. This way only cat has to run as root.
View a Lord of the Rings timeline easter egg in calendar
alias gethist 'grep \!^ /var/log/foo.log' would do the same, but optimized.
View a Lord of the Rings timeline easter egg in calendar
Try
. I forgot the backslash away in my first post..
|
SearchFrom our Sponsor...Latest Mountain Lion HintsWhat's New:HintsNo new hintsComments last 2 daysNo new commentsLinks last 2 weeksNo recent new linksWhat's New in the Forums?
Hints by TopicNews from Macworld
From Our Sponsors |
|
Copyright © 2014 IDG Consumer & SMB (Privacy Policy) Contact Us All trademarks and copyrights on this page are owned by their respective owners. |
Visit other IDG sites: |
|
|
|
Created this page in 0.06 seconds |
|