3762
Comment: WIP link to CommandLineInterface/DesktopEnvironment, add WP link, add categories, add todo, formatting, wording
|
3780
WIP formatting , links
|
Deletions are marked like this. | Additions are marked like this. |
Line 21: | Line 21: |
An interactive shell is used by a user in a virtual console or a terminal emulator. The default interactive shell is DebianPkg:bash. The default interactive shell for newly created users can be set in {{{/etc/adduser.conf}}}. | An interactive shell is used by a user in a virtual console or a terminal emulator. Debian uses [[Bash]] as the default non-interactive shell. The default interactive shell for newly created users can be set in {{{/etc/adduser.conf}}}. |
A shell is a piece of software that provides an interface for users. Nowadays the term shell is mostly used for CommandLineInterface shells.
"Graphical shell" is a rarely used term for a DesktopEnvironment.
Default Non-interactive Shell
A non-interactive shell is used to execute system scripts or scripts that use #!/bin/sh shebang.
Debian uses Dash as the default non-interactive shell.
It is not intended to be used interactively by a user, for example, in a terminal emulator, but rather focuses on compatibility with POSIX standards. Therefore, many interactive features are not present in Dash, making it faster and more memory efficient than Bash.
Before DebianSqueeze, Bash was used as the default non-interactive shell.
Default Interactive shell
An interactive shell is used by a user in a virtual console or a terminal emulator.
Debian uses Bash as the default non-interactive shell.
The default interactive shell for newly created users can be set in /etc/adduser.conf.
Changing a User's Default Interactive Schell
Check which shells are currently installed:
$ cat /etc/shells
/bin/sh /bin/dash /bin/bash /bin/rbash /bin/zsh /usr/bin/zsh
Change the default shell:
$ chsh
Enter the new value, or press return for the default Login Shell [/bin/bash]: /bin/zsh
Restart the terminal emulator for the change to take effect.
Available shells
Debian provides many different shells ( see http://packages.debian.org/stable/shells/ ), many of them are still provided for compatibility with existing assets.
The main shells:
bash - A very powerful shell, with very good interactive interface.
dash - A fast shell, compliant with debian-policy and SUSv3.
mksh - A fast Korn_shell, compliant with Debian Policy §10.4 and SUSv4. Also contains mksh-static, which might be an even better /bin/sh choice.
zsh - Another powerful shell (see http://zsh.dotsrc.org/Intro/).
fish - Another friendly interactive shell.
Note on some other shells:
busybox - A Tiny shell, used in initrd and in DebianInstaller.
csh and tcsh should be avoided as scripting languages. See Csh Programming Considered Harmful, one of the comp.unix.* FAQs, which can be found at http://www.faqs.org/faqs/unix-faq/shell/csh-whynot/.
See also
?BriefHistoryOfShells
TODO: refactor this page