linux shell facts

Ace your homework & exams now with Quizwiz!

what is a shell?

A Linux shell is a program that traditionally provides the text user interface (TUI) for Linux. The term shell is descriptive since it is considered an outer layer of the operating system. The shell's main function is to read and parse your commands and then execute them through interactions with the Linux kernel.

shh

The Bourne shell (sh) is an earlier version of Bash and is similar in many ways. The sh shell was originally created by Steve Bourne.

sh

The Bourne shell is the oldest Linux shell but is not widely used. This shell was developed for UNIX in the 1970s.

bash

The Bourne-Again shell (Bash) is the default shell used by most Linux distributions. It uses commands similar to a UNIX shell. The Bash includes: Command and file name completion when pressing the Tab key.

csh

The C shell (csh) uses syntax similar to the syntax used in the C programming language.

ksh

The Korn shell (ksh) provides scripting features not found in Bash. Ksh was developed by David Korn.

zsh

The Z shell (zsh) is an improved version of Bash and is available on many Linux distributions.

echo $0

The echo $0 command can be used to return the current shell type. The special variable $0 normally holds the command used to start a script. A shell session is initiated by a script. Consequently, $0 will hold the name of the script, which is consistent with the shell type. For example, $0 in a console session running bash might hold the value -bash , $0 in a terminal application opened from a desktop menu might hold the value bash . When you type ksh , the ksh script is run, a Korn shell session is opened, and $0 will hold the value ksh .

echo $SHELL

The echo $SHELL command returns the default or preferred shell. The environment $SHELL holds the user's preferred shell, which is typically set in /etc/passwd . For example, if Bash is the user's preferred shell, $SHELL will hold the value /bin/bash . The preferred shell does not change when you switch shell types.

tcsh

The tcsh shell is an improved version of csh. It offers command line editing and completion features that are not available in csh.


Related study sets

History Chapter 13 Review Questions

View Set

Chapter 06: Introduction to the Internet Protocol

View Set

Macroeconomics Unit 3 Test Review

View Set

Motor and Air Conditioning calculations

View Set

Esthetics TEST Chapter 1 -22 for state board prep

View Set

Emotional and Personality Development

View Set

Artificial Intelligence Companies in US

View Set