FazBrowse Wikipedia Viewer | Main Page |
Search Wikipedia:
|
Viewing: https://en.wikipedia.org/wiki/Unix_shell

Unix shell

tcsh and sh shell windows on a Mac OS X Leopard desktop

A Unix shell is a shell that provides a command-line user interface for a Unix-like operating system. A Unix shell provides a command language that can be used either interactively or for writing a shell script. A user typically works within a Unix shell via a terminal emulator; however, direct access via serial hardware connections or a Secure Shell are common for server systems. Although use of a Unix shell is popular with some users, others prefer to use a graphical shell in a windowing system, such as those provided in desktop Linux distributions or macOS, instead of a command-line interface (CLI).

A user may have access to multiple Unix shells with one configured to run by default when the user logs in interactively. The default selection is typically stored in a user's profile (for example, in the local passwd file or in a distributed configuration system such as NIS or LDAP). A user may use other shells nested inside the default shell.

A Unix shell may provide many features including: variable definition and substitution, command substitution, filename wildcarding, stream piping, control flow structures (condition-testing and iteration), working directory context, and here document.

/bin/sh. But a number of compatible work-alikes are also available with various improvements and additional features. On many systems, sh may be a symbolic link or hard link to one of these alternatives:

The POSIX standard specifies its standard shell as a strict subset of the Korn shell. From a user's perspective the Bourne shell was immediately recognized when active by its characteristic default command line prompt character, the dollar sign (/etc/csh.login login login /etc/ksh.kshrc int. ~/.kshrc) int. int. int. /etc/profile login login login login ~/.bash_login login /etc/zshenv yes /etc/zlogin login ~/.zprofile login ~/.zlogout login

Explanation:

~/.tcshrc not found
  • ↑ Newer versions of the Bourne Shell only
  • ↑ Available on systems that support the "User Portability Utilities option"; value of the variable must be an absolute path, and it is ignored "if the user's real and effective user IDs or real and effective group IDs are different."
  • ↑ sh, but only if invoked as -o posix).
  • 1 2 Only in sh/ksh compatibility mode (when invoked as bash, sh, ksh)
  • 1 2 3 The first readable file in order of ~/.profile; and only --posix or
    "V6 Thompson Shell Port - History". V6shell.org. Retrieved 2012-08-14.
  • ↑ Bourne, Stephen (2009-03-05). "The A-Z of Programming Languages: Bourne shell, or sh" (Interview). Interviewed by Howard Dahdah. Computerworld. Archived from the original on 2022-08-16. Retrieved 2022-08-16.
  • ↑ Harley Hahn. "Unix/Linux Timeline". Harley Hahn's Guide to Unix and Linux.
  • ↑ Harley Hahn. "Exercises and Answers for Chapter 14... Using The Shell: Initialization Files". Harley Hahn's Guide to Unix and Linux.
  • ↑ "FreeBSD Ports: Shells". Freebsd.org. 2014-03-30. Archived from the original on 2021-01-12. Retrieved 2014-04-05.
  • Commons

    View original on Wikipedia | Back | FazBrowse Home