News for hackers. Stuff that matters.
Re:Which is not Posix by jfrunyon on Monday November 01, 2021 @05:35PM (#29073460)
Correct, because they do two different things.

`which` is a standalone executable which searches the environment's PATH for the named command. It doesn't know about commands which aren't executables (i.e. builtins and aliases).

`command` is a shell builtin which tells you exactly what that shell in its current state would run.

Re:Which is not Posix by jonnycomputer on Monday November 01, 2021 @08:08PM (#29075142)
Interesting, and useful to know. Thanks for that.