Remix.run Logo
stabbles 6 hours ago

Nowadays [ is a builtin. The subprocess for a simple branch would be excessive overhead.

MontyCarloHall 6 hours ago | parent [-]

It is indeed a builtin, but `/bin/[` still exists for compatibility reasons!

   $ which [
   /bin/[
   $ type [
   [ is a shell builtin
The same is true for the `test` command:

   $ which test
   /bin/test
   $ type test
   test is a shell builtin
stabbles 4 hours ago | parent [-]

Right, that's also a good reminder that the builtin `command -V` is typically what you want whenever you use not-always-builtin `which` ;)