This is the mail archive of the
cygwin-apps
mailing list for the Cygwin project.
Re: [RFC] /etc/shells management (fish, mksh, posh, tcsh, zsh)
- From: Andrew Schulman <schulman dot andrew at epa dot gov>
- To: cygwin-apps at cygwin dot com
- Date: Fri, 13 May 2016 06:29:23 -0400
- Subject: Re: [RFC] /etc/shells management (fish, mksh, posh, tcsh, zsh)
- Authentication-results: sourceware.org; auth=none
- References: <pe94jbtrjf32qn2u0mbtrful36o1trjguj at 4ax dot com> <ngvnm4$tms$1 at ger dot gmane dot org> <lro6jbph7mumea7qcf0jbdnut23kujk3i4 at 4ax dot com> <cf899cc5-4267-3f59-478e-b7ba5361e2eb at cygwin dot com> <cf899cc5-4267-3f59-478e-b7ba5361e2eb-rDBXBDvO6BXQT0dZR+AlfA at public dot gmane dot org> <b6d3465f-6630-5e05-bd35-30fb7d005304 at cygwin dot com>
> On 2016-05-11 14:06, Yaakov Selkowitz wrote:
> > On 2016-05-11 12:09, Andrew Schulman wrote:
> >>> Am 10.05.2016 um 20:19 schrieb Andrew Schulman:
> >>>> Achim, can you please add /bin/fish and /usr/bin/fish to /etc/shells in
> >>>> base-files?
> >>>
> AFAICS this should be a two-step process.
>
> 1) base-files' default /etc/shells should contain only the shells in a
> Base install, namely:
>
> /bin/sh
> /bin/ash
> /bin/bash
> /bin/dash
> /usr/bin/sh
> /usr/bin/ash
> /usr/bin/bash
> /usr/bin/dash
> /sbin/nologin
Yep.
> 2) Then all non-Base shells, namely:
>
> fish Andrew Schulman
> mksh Chris Sutcliffe
> posh Jari Aalto
> tcsh Corinna Vinschen
> zsh Peter A. Castro
>
> will bump release adding an update_etc_shells call, per the attached
> patch, with the path of their shell(s).
Agreed.
> Attached. Any questions or comments before I make this official?
This looks right, except that it edits /etc/shells directly. So if a person
edits /etc/shells to remove, say, fish, and fish gets updated, as written this
patch will add fish back in. (Why they'd install fish but not want it in
/etc/shells I don't know, but it's possible.)
Better is to add the new shell to /etc/default/etc/shells, then copy that file
over /etc/shells if that file had not been previously edited.
> Or, is this just not worth the trouble? What are the consequences of
> having shells listed in /etc/shells which aren't on the system?
/etc/shells doesn't seem to be very important in Cygwin. And it includes one
shell now (pdksh) that doesn't exist in Cygwin, and it's not hurting anything.
But it's not a lot of work to do it right, and I think we should.
Andrew