I'd like to add my 2 cents, too.

I agree that "which" should be a shell-builtin, because it is
dependant on how the shell will search and performe a command
(it might be an alias, a shell function, or a shell-builtin,
or a "normal" program).

Personally, I use the zsh, and its "which" builtin has served
me very well (zsh also supports "type" according to POSIX).
Another useful command is "where", which prints all possible
locations of a command, in order of preference (not just the
first one like "which" does).

Finally, I like the "path expansion" feature very much:  an
equal sign followed by a command name will expand to the full
path of the command.  For example, "vi =foo" is an easy way to
edit the foo script, no matter where it is and where my cwd is,
and "file =bar" tells me if bar is a binary, a shell script, a
perl hack or whatever, without having to know where it is.

Regards
   Oliver

-- 
Oliver Fromme, Leibnizstr. 18/61, 38678 Clausthal, Germany
(Info: finger userinfo:[EMAIL PROTECTED])

"In jedem Stück Kohle wartet ein Diamant auf seine Geburt"
                                         (Terry Pratchett)


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to