On Sat, Feb 03, 2001 at 05:27:20PM -0800, Cory Petkovsek wrote:
>
>Hey!  That units program is cool! Thanks Bob!
>
>Like Rob's call for cool command line tricks, I'd like to make a similar call for 
>other programs like units.  What programs are hidden within the depths of *nix that 
>some of you old unix gurus know about?
>

Well, i find "head" and "tail" very useful.  For example, the process id
number of sendmail is stored in /var/run/sendmail.pid, as is a bunch of other
info; i can restart sendmail with "kill -HUP `head -n 1 /var/run/sendmail.pid`".
Similar tricks with /proc info are no doubt applicable.  Head and tail can be
useful for stripping excess data from records;

---
bash$whois efn.org | tail -n 42 | head

Registrant:
Oregon Public Networking (EFN-DOM)
   P.O. Box 1914
   Eugene, OR 97440

   Domain Name: EFN.ORG

   Administrative Contact:
      OPN Operations  (OO31-ORG)  [EMAIL PROTECTED]
bash$ 
---

Some find dc useful; i've not done much with it.

-- 
Yes, we ARE a bunch of anal, short-tempered, quick to fly-off-the-handle, 
sarcastic, know-it-alls.  That's what running networks does to you.

                                - James Fischer on inet-access

Reply via email to