Stupid bash question
Joe Smith
jes at martnet.com
Tue Dec 11 17:05:31 UTC 2007
Mikkel L. Ellertson wrote:
> One thing that would probably help your understanding is that [ is
> actually a command. It is usually a shell built-in command, but it
> is also a command in /usr/bin, and is the same as the test command.
> ...
Mmm, curious. I wonder why are they /not/ the same command?
$ type [ test
[ is a shell builtin
test is a shell builtin
$ ls -li /usr/bin/{[,test}
1234416 -rwxr-xr-x 1 root root 31404 2007-12-05 08:25 /usr/bin/[
1234972 -rwxr-xr-x 1 root root 29032 2007-12-05 08:24 /usr/bin/test
I always thought that [ and test were links to the same binary.
I guess disk blocks aren't as precious as they once were ;-)
<Joe
More information about the fedora-list
mailing list