Live data from Hacker News

Which is not Posix

hynek.me

21–30 of 97 posts

Re: Which is not Posix

#21

Not sure why the outcome of "`which` is not POSIX" would be "essentially everybody should stop using `which` and start using `command -v`, which is poorly known, has different semantics, and is covered in relatively little introductory material" rather than "this is just another example of why POSIX has been nearly irrelevant for a long time now". systemd is not POSIX, either, but that's not taken as some justificati…

So… bike shedding?

Re: Which is not Posix

#22
Who cares? When I want to know where my python comes from, I which it. Oh, that's the virtualenv, thanks.

Unless you doing alternative micro meta alpine docker images, this has no importance whatsoever.

Re: Which is not Posix

#23
post #2

Yeah, no thanks, I'm going to keep using `which`, and distributions are going to support it, no matter how "standard" `command -v` is. The only reason we're talking about this is that it's so noteworthy that any distro would seriously suggest people avoid `which`, which is the de facto standard.

There are enough dists which don't support which.

Re: Which is not Posix

#26

Not sure why the outcome of "`which` is not POSIX" would be "essentially everybody should stop using `which` and start using `command -v`, which is poorly known, has different semantics, and is covered in relatively little introductory material" rather than "this is just another example of why POSIX has been nearly irrelevant for a long time now". systemd is not POSIX, either, but that's not taken as some justificati…

As the Debian brouahaha pointed out, there are multiple incompatible implementations of which, so it's unclear which one (ha ha) POSIX should standardize on (and is it politically realistic to anoint one as the 'winner'?).

As for systemd, AFAIK system startup isn't covered by POSIX at all, so bsd init, sysv init and systemd are all equally not covered by POSIX. Which is fine, POSIX was never meant to cover every single behavior of an OS, but rather a sort of least common denominator to make porting easier (not "make porting non-existent").

Re: Which is not Posix

#27

Not sure why the outcome of "`which` is not POSIX" would be "essentially everybody should stop using `which` and start using `command -v`, which is poorly known, has different semantics, and is covered in relatively little introductory material" rather than "this is just another example of why POSIX has been nearly irrelevant for a long time now". systemd is not POSIX, either, but that's not taken as some justificati…

[deleted]

Re: Which is not Posix

#28
post #23
post #2

Yeah, no thanks, I'm going to keep using `which`, and distributions are going to support it, no matter how "standard" `command -v` is. The only reason we're talking about this is that it's so noteworthy that any distro would seriously suggest people avoid `which`, which is the de facto standard.

There are enough dists which don't support which.

Any that more than 10 people use?

Re: Which is not Posix

#30
post #25

let's collectively mark POSIX as deprecated and move on

It's better to create a «PWG» (POSIX Working Group), which then publish POSIX2021, POSIX2026, and so on.

This already exists:

* https://en.wikipedia.org/wiki/Austin_Group

* https://www.opengroup.org/austin/

* https://www.austingroupbugs.net/main_page.php

* https://www.mail-archive.com/austin-group-l@opengroup.org/ma...

There are drafts available for a 202x revision (have to register an account).

See also:

* https://unix.org/

* https://twitter.com/unixr

Post reply on HN