3 ms·
> [ ] is a command—basically another way to call the built-in test command. Literally, '/usr/bin/[', which takes as an argument a final ']', but actually a dif
by peterwwillis 7y ago
> [ ] is a command—basically another way to call the built-in test command.
Literally, '/usr/bin/[', which takes as an argument a final ']', but actually a different binary than '/usr/bin/test'. And is different from the bash builtin. Crazy shit.
vagrant@vagrant:~$ [ --version
-bash: [: missing `]'
vagrant@vagrant:~$ /usr/bin/[ --version
[ (GNU coreutils) 8.28
Copyright (C) 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Written by Kevin Braunsdorf and Matthew Bradburn.
- kohtatsu 7y agoI think it's cute.