* Kent West (westk@acu.edu) [020926 12:00]:
> I did a "chown +x test". From my home directory (/home/westk), I can run
> "test" and I get no output. However, if I specify "bin/test", I get the
> expect message ("This is a test"). If I do a "which test", it reports
> "/home/westk/bin/test".
Yet another reason to use 'type' instead of 'which':
vineet@pianoman ~ % type test
test is a shell builtin
vineet@pianoman ~ % type which
which is a shell builtin
Oops, I cheated: I use zsh =)
vineet@pianoman ~ % bash
vineet@pianoman:~$ type test
test is a shell builtin
vineet@pianoman:~$ type which
which is /usr/bin/which
vineet@pianoman:~$ file /usr/bin/which
/usr/bin/which: Bourne-Again shell script text executable
For a more complete discussion, try:
man bash
/ *type
good times,
Vineet
--
http://www.doorstop.net/
--
#include<stdio.h>
int main() {
puts("Reader! Think not that \n"
"technical information \n"
"ought not be called speech;");
return 0;
}
Attachment:
pgp2YGh6RR4wg.pgp
Description: PGP signature