Shell Games

Tom Huppi thuppi at huppi.com
Fri Dec 31 00:53:44 PST 2004




On Fri, 31 Dec 2004, vijayendra gadgil wrote:

> On Fri, 31 Dec 2004 00:30:16 -0500 (EST), Tom Huppi <thuppi at huppi.com> wrote:

<snip>

> > FWIW, I've always used 'tcsh' interactively, but almost switched a
> > while back out of disgust at not being able to figure out how to
> > get a one-line foreach/{do_something}/end loop (which would allow
> > me to re-run a complex command easily.)
>
> I would recommend 'ksh' it does the tasks of both 'csh' and 'sh' with
> advanced programming features, check out http://www.kornshell.com/

As it happens, my attempts to do this one-liner with 'tcsh' were a
direct result of watching someone who used 'ksh'.  I thought it
probable that 'bash' also could accomplish this feat (and maybe
'tcsh' also if I could figure it out.)  Anyone know?

IIRC, I solved the immediate issue with either find/-exec, or a
ubiquitous and simple utility called 'checksed' (and it's friends.)
After that, I ran out of incentive to change shells :)

This being the newbies list, I should like to mention that I've
found both 'find' and 'checksed/runsed' to be really useful over
the years.  They are two things that I have been happy to have
spend the effort necessary to learn what they are and their basic
usage.

Thanks,

 - Tom


More information about the freebsd-newbies mailing list