Re: [HEADSUP] making /bin/sh the default shell for root

From: Piotr P. Stefaniak <>
Date: Wed, 22 Sep 2021 12:59:23 UTC
On 2021-09-22 10:36:45, Baptiste Daroussin wrote:

>Recently our sh(1) has receive update to make it more user friendly in
>interactive mode:
>* command completion (thanks pstef@)
>* improvement in the emacs mode, to make it behave by default like other shells
>* improvement in the vi mode (in particular the vi edit to respect $EDITOR)
>* support for history as described by POSIX.

There are also prompt-related commits done by trasz:
r342577 Make sh(1) collapse $HOME into "~" in PS1
r342576 Simplify the way we set the default sh(1) PS1
r342645 Add current working directory to the default sh prompt
r342812 Give sh(1) a proper default prompt instead of just "$".
r342881 Make sh(1) recognize the default $HOME
r343231 Don't mess with BLOCKSIZE in shell startup files
r343399 Make sh(1) support \u in PS1
r343416 Install .shrc for root, and set PS1 for the toor account.

and this commit by me:
r363621 sh(1): print a newline when ^D quits sh

What I would like to see by default are these ctrl-arrow bindings in
emacs mode and an alias for "history":
bind "\\e[1;5C" em-next-word
bind "\\e[1;5D" ed-prev-word
alias history='fc -l'