summaryrefslogtreecommitdiff
path: root/devdocs/bash/interactive-shell-behavior.html
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2024-04-07 13:41:34 -0500
committerCraig Jennings <c@cjennings.net>2024-04-07 13:41:34 -0500
commit754bbf7a25a8dda49b5d08ef0d0443bbf5af0e36 (patch)
treef1190704f78f04a2b0b4c977d20fe96a828377f1 /devdocs/bash/interactive-shell-behavior.html
new repository
Diffstat (limited to 'devdocs/bash/interactive-shell-behavior.html')
-rw-r--r--devdocs/bash/interactive-shell-behavior.html27
1 files changed, 27 insertions, 0 deletions
diff --git a/devdocs/bash/interactive-shell-behavior.html b/devdocs/bash/interactive-shell-behavior.html
new file mode 100644
index 00000000..f7d7d665
--- /dev/null
+++ b/devdocs/bash/interactive-shell-behavior.html
@@ -0,0 +1,27 @@
+<h1 class="subsection">Interactive Shell Behavior</h1> <p>When the shell is running interactively, it changes its behavior in several ways. </p> <ol> <li> Startup files are read and executed as described in <a href="bash-startup-files">Bash Startup Files</a>. </li>
+<li> Job Control (see <a href="job-control">Job Control</a>) is enabled by default. When job control is in effect, Bash ignores the keyboard-generated job control signals <code>SIGTTIN</code>, <code>SIGTTOU</code>, and <code>SIGTSTP</code>. </li>
+<li> Bash expands and displays <code>PS1</code> before reading the first line of a command, and expands and displays <code>PS2</code> before reading the second and subsequent lines of a multi-line command. Bash expands and displays <code>PS0</code> after it reads a command but before executing it. See <a href="controlling-the-prompt">Controlling the Prompt</a>, for a complete list of prompt string escape sequences. </li>
+<li> Bash executes the values of the set elements of the <code>PROMPT_COMMAND</code> array variable as commands before printing the primary prompt, <code>$PS1</code> (see <a href="bash-variables">Bash Variables</a>). </li>
+<li> Readline (see <a href="command-line-editing">Command Line Editing</a>) is used to read commands from the user’s terminal. </li>
+<li> Bash inspects the value of the <code>ignoreeof</code> option to <code>set -o</code> instead of exiting immediately when it receives an <code>EOF</code> on its standard input when reading a command (see <a href="the-set-builtin">The Set Builtin</a>). </li>
+<li> Command history (see <a href="bash-history-facilities">Bash History Facilities</a>) and history expansion (see <a href="history-interaction">History Expansion</a>) are enabled by default. Bash will save the command history to the file named by <code>$HISTFILE</code> when a shell with history enabled exits. </li>
+<li> Alias expansion (see <a href="aliases">Aliases</a>) is performed by default. </li>
+<li> In the absence of any traps, Bash ignores <code>SIGTERM</code> (see <a href="signals">Signals</a>). </li>
+<li> In the absence of any traps, <code>SIGINT</code> is caught and handled (see <a href="signals">Signals</a>). <code>SIGINT</code> will interrupt some shell builtins. </li>
+<li> An interactive login shell sends a <code>SIGHUP</code> to all jobs on exit if the <code>huponexit</code> shell option has been enabled (see <a href="signals">Signals</a>). </li>
+<li> The <samp>-n</samp> invocation option is ignored, and ‘<samp>set -n</samp>’ has no effect (see <a href="the-set-builtin">The Set Builtin</a>). </li>
+<li> Bash will check for mail periodically, depending on the values of the <code>MAIL</code>, <code>MAILPATH</code>, and <code>MAILCHECK</code> shell variables (see <a href="bash-variables">Bash Variables</a>). </li>
+<li> Expansion errors due to references to unbound shell variables after ‘<samp>set -u</samp>’ has been enabled will not cause the shell to exit (see <a href="the-set-builtin">The Set Builtin</a>). </li>
+<li> The shell will not exit on expansion errors caused by <var>var</var> being unset or null in <code>${<var>var</var>:?<var>word</var>}</code> expansions (see <a href="shell-parameter-expansion">Shell Parameter Expansion</a>). </li>
+<li> Redirection errors encountered by shell builtins will not cause the shell to exit. </li>
+<li> When running in <small>POSIX</small> mode, a special builtin returning an error status will not cause the shell to exit (see <a href="bash-posix-mode">Bash POSIX Mode</a>). </li>
+<li> A failed <code>exec</code> will not cause the shell to exit (see <a href="bourne-shell-builtins">Bourne Shell Builtins</a>). </li>
+<li> Parser syntax errors will not cause the shell to exit. </li>
+<li> If the <code>cdspell</code> shell option is enabled, the shell will attempt simple spelling correction for directory arguments to the <code>cd</code> builtin (see the description of the <code>cdspell</code> option to the <code>shopt</code> builtin in <a href="the-shopt-builtin">The Shopt Builtin</a>). The <code>cdspell</code> option is only effective in interactive shells. </li>
+<li> The shell will check the value of the <code>TMOUT</code> variable and exit if a command is not read within the specified number of seconds after printing <code>$PS1</code> (see <a href="bash-variables">Bash Variables</a>). </li>
+</ol><div class="_attribution">
+ <p class="_attribution-p">
+ Copyright &copy; 2000, 2001, 2002, 2007, 2008 Free Software Foundation, Inc.<br>Licensed under the GNU Free Documentation License.<br>
+ <a href="https://www.gnu.org/software/bash/manual/html_node/Interactive-Shell-Behavior.html" class="_attribution-link">https://www.gnu.org/software/bash/manual/html_node/Interactive-Shell-Behavior.html</a>
+ </p>
+</div>