Although posh definitely has some utility with respect to portability testing, it is not a compliant implementation of the Shell Command Language, as defined by POSIX.1-2008 or later. For example: $ posh -c 'command -v ls' command: invalid option -- 'v' $ posh -c 'command -V ls' command: invalid option -- 'V This is an example of two switches that were optional in POSIX.1-2004, per the "User Portability Utilities" provisions, but not as of POSIX.1-2008. In my view, this doesn't cut it in 2020. For a Gentoo user to select a /bin/sh implementation that is only compliant with the mandatory parts of POSIX.1-2004 stands a high chance of failing with scripts in the wild. If that does not seem sufficently persuasive, consider that there is no shortage of openrc runscripts that will break, including "bootmisc", "local", "loopback" and "net.lo". Essentially, nobody in the Linux world is really interested in strict POSIX.1-2004 compliance at this juncture. It's hard enough to get people to write scripts that are even compliant with the current specs [1]. Therefore, I suggest simply not offering posh as an option in eselect-sh. [1] For instance, gentoo runscripts constantly use the entirely non-standard local keyword although that is the fault of their authors and not posh, which is definitely under no obligation to implement it.
I guess this makes sense.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=761b42c9fdae7c8cd01615be8d2b4f6cad5c3443 commit 761b42c9fdae7c8cd01615be8d2b4f6cad5c3443 Author: Michał Górny <mgorny@gentoo.org> AuthorDate: 2020-05-17 13:35:35 +0000 Commit: Michał Górny <mgorny@gentoo.org> CommitDate: 2020-05-17 13:36:36 +0000 app-eselect/eselect-sh: Remove posh from targets Closes: https://bugs.gentoo.org/720996 Signed-off-by: Michał Górny <mgorny@gentoo.org> app-eselect/eselect-sh/eselect-sh-0.4.1.ebuild | 21 +++++++++++++++++++++ app-eselect/eselect-sh/files/sh.eselect-0.4.1 | 13 +++++++++++++ 2 files changed, 34 insertions(+)