v03i085: Re: v03i081: a csh alias to print out the path with reference numbers

Philip Saeli - Sun Tactical Engineering boris at Sun.COM
Mon Jul 18 12:30:20 AEST 1988


Posting-number: Volume 3, Issue 85
Submitted-by: "Philip Saeli - Sun Tactical Engineering" <boris at Sun.COM>
Archive-name: epf

Hmmmm, I tried this alias and it executes relatively slowly on my workstation
(a Sun 3/160 running SunOS 4.0).  I have an alias I've been using for a
while now that runs much faster, even though it forks an external command.
I've called it "epf" for "echo path formatted".  Kind of baroque, but
it went with other aliases that I have.  Here it is:

alias epf \
 echo \$path \| "awk '{for(i=1; i<=NF; i++) printf" '"%3d: %s\n", i-1, $i}'"'"

Speed is important to me as I have about 30 directories in my path.


Philip Saeli	Sun Microsystems, Inc.
sun!psaeli	psaeli at sun.com



More information about the Comp.sources.misc mailing list