[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: What are desired semantics for /etc/shells?



Hi,

* Helmut Grohne <helmut@subdivi.de> [2021-06-24 08:10]:
> Felix C. Stegerman cautioned that the contents of /etc/shells depends on
> whether the underlying system is /usr-merged.

It also means that on /usr-merged systems e.g. /bin/screen is not a
"valid" shell, but /usr/bin/screen is (even though they are the same
file), which may be fine in practice but seems counter-intuitive to
me.

>  * While the order of /etc/shells will not be sorted, it will be
>    deterministic if update-shells is run after all packages have been
>    unpacked. Installing two packages one after another will still cause
>    their order in /etc/shells to differ, but changing the order of
>    /etc/shells could break comments left by administrators. So this is a
>    compromise that partially improves reproducibility without regressing
>    maintainability of /etc/shells. I hope that it is sufficient in
>    practice.

Sorting /etc/shells if the only comment in it is the current
|# /etc/shells: valid login shells
on line 1 would seem acceptable to me.

> for f in "$PKG_DIR/"*; do

Would it make sense to set LC_COLLATE for deterministic ordering here?

- Felix


Reply to: