TCLUG Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [TCLUG:9065] More regex...
> And... When I use 'locate' I would like to be able to point it to just the
> exact match for a file name.
> Ex:
>
> locate traceroute
>
> returns:
>
> /usr/doc/kde/HTML/en/knu/knu-traceroute.gif
> /usr/man/man8/traceroute.8
> /usr/sbin/traceroute
> /home/insyte/.kpackage/traceroute-1.4a5-16.i386.rpm
>
> when all I really wanted was /usr/sbin/traceroute.
In addition to the command line Jon Schewe gave, you could use something
along the lines of
locate traceroute | grep bin
Which will filter it down to anything in a path that has 'bin' in it
(/bin, /usr/bin, /sbin, /usr/sbin, etc.)
*shrug* Whatever, just play with it..
--
_ _ _ _ _ ___ _ _ _ ___ _ _ __ I have a rock garden.
/ \/ \(_)| ' // ._\ / - \(_)/ ./| ' /(__ Three of them died last
\_||_/|_||_|_\\___/ \_-_/|_|\__\|_|_\ __) week.
[ Mike Hicks | http://umn.edu/~hick0088 | mailto:hick0088@tc.umn.edu ]