📄 ch04_01.htm
字号:
<html><head><title>The Bourne Shell and Korn Shell (UNIX in a Nutshell: System V Edition)</title><link rel="stylesheet" type="text/css" href="../style/style1.css" /><meta name="DC.Creator" content="Arnold Robbins" /><meta name="DC.Format" content="text/xml" scheme="MIME" /><meta name="DC.Language" content="en-US" /><meta name="DC.Publisher" content="O'Reilly & Associates, Inc." /><meta name="DC.Source" scheme="ISBN" content="1-56592-427-4" /><meta name="DC.Subject.Keyword" content="stuff" /><meta name="DC.Title" content="UNIX in a Nutshell: System V Edition" /><meta name="DC.Type" content="Text.Monograph" /></head><body bgcolor="#ffffff"><img src="gifs/smbanner.gif" usemap="#banner-map" border="0" alt="Book Home" /><map name="banner-map"><area shape="rect" coords="1,-2,616,66" href="index.htm" alt="Book Title" /><area shape="rect" coords="629,-11,726,25" href="jobjects/fsearch.htm" alt="Search this book" /></map><div class="navbar"><table width="684" border="0"><tr><td align="left" valign="top" width="228"><a href="ch03_05.htm"><img src="../gifs/txtpreva.gif" alt="Previous" border="0" /></a></td><td align="center" valign="top" width="228" /><td align="right" valign="top" width="228"><a href="ch04_02.htm"><img src="../gifs/txtnexta.gif" alt="Next" border="0" /></a></td></tr></table></div><h1 class="chapter">Chapter 4. The Bourne Shell and Korn Shell</h1><div class="htmltoc"><h4 class="tochead">Contents:</h4><p><a href="ch04_01.htm#sect1">Overview of Features</a><br /><a href="ch04_02.htm">Syntax</a><br /><a href="ch04_03.htm">Variables</a><br /><a href="ch04_04.htm">Arithmetic Expressions</a><br /><a href="ch04_05.htm">Command History</a><br /><a href="ch04_06.htm">Job Control</a><br /><a href="ch04_07.htm">Invoking the Shell</a><br /><a href="ch04_08.htm">Restricted Shells</a><br /><a href="ch04_09.htm">Built-in Commands (Bourne and Korn Shells)</a><br /></p></div><p>This chapter presents the following topics:<a name="unut-ch-4-ix-sh-bourne-shell" /><a name="unut-ch-4-ix-ksh-korn-shell" /></p><ul><li><p>Overview of features</p></li><li><p>Syntax</p></li><li><p>Variables</p></li><li><p>Arithmetic expressions (Korn shell only)</p></li><li><p>Command history (Korn shell only)</p></li><li><p>Job control</p></li><li><p>Invoking the shell</p></li><li><p>Restricted shells</p></li><li><p>Built-in commands</p></li></ul><p>http://www.kornshell.comprovides considerable information about the Korn shell.Follow the links there for binaries of <tt class="literal">ksh93</tt>that can be downloaded for noncommercial and educational use.See also <em class="citetitle"><a href="../korn/index.htm">Learning the Korn Shell</a></em>, which is listed in the <a href="biblio.htm">Bibliography</a>.</p><div class="sect1"><a name="unut-ch-4-sect-1" /><h2 class="sect1"><a name="sect1" />4.1. Overview of Features</h2><p>The Bourne shell is the standard shell and provides the followingfeatures:</p><ul><li><p>Input/output redirection</p></li><li><p>Wildcard characters (metacharacters) for filename abbreviation</p></li><li><p>Shell variables for customizing your environment</p></li><li><p>A built-in command set for writing shell programs</p></li><li><p>Job control (beginning in SVR4)</p></li></ul><p>The Korn shell is a backward-compatible extension of the Bourne shell.Features that are valid only in the Korn shell areso indicated:</p><ul><li><p>Command-line editing (using the command syntax of either<tt class="literal">vi</tt> or <tt class="literal">emacs</tt>)</p></li><li><p>Access to previous commands (command history)</p></li><li><p>Integer arithmetic</p></li><li><p>More ways to match patterns and substitute variables</p></li><li><p>Arrays and arithmetic expressions</p></li><li><p>Command-name abbreviation (aliasing)</p></li><li><p>More built-in commands</p></li></ul><p><tt class="literal">ksh93</tt> adds the following capabilities:</p><ul><li><p>Upwards compliance with POSIX</p></li><li><p>Internationalization facilities</p></li><li><p>An arithmetic <tt class="literal">for</tt> loop</p></li><li><p>Floating-point arithmetic and built-in arithmetic functions</p></li><li><p>Structured variable names and indirect variable references</p></li><li><p>Associative arrays</p></li><li><p>Even more ways to match patterns and substitute variables</p></li><li><p>Even more built-in commands</p></li></ul></div><hr width="684" align="left" /><div class="navbar"><table width="684" border="0"><tr><td align="left" valign="top" width="228"><a href="ch03_05.htm"><img src="../gifs/txtpreva.gif" alt="Previous" border="0" /></a></td><td align="center" valign="top" width="228"><a href="index.htm"><img src="../gifs/txthome.gif" alt="Home" border="0" /></a></td><td align="right" valign="top" width="228"><a href="ch04_02.htm"><img src="../gifs/txtnexta.gif" alt="Next" border="0" /></a></td></tr><tr><td align="left" valign="top" width="228">3.5. Differing Features</td><td align="center" valign="top" width="228"><a href="index/index.htm"><img src="../gifs/index.gif" alt="Book Index" border="0" /></a></td><td align="right" valign="top" width="228">4.2. Syntax</td></tr></table></div><hr width="684" align="left" /><img src="../gifs/navbar.gif" usemap="#library-map" border="0" alt="Library Navigation Links" /><p><p><font size="-1"><a href="copyrght.htm">Copyright © 2003</a> O'Reilly & Associates. All rights reserved.</font></p><map name="library-map"><area shape="rect" coords="1,0,88,96" href="../index.htm"><area shape="rect" coords="90,0,165,96" href="../upt/index.htm"><area shape="rect" coords="168,1,253,107" href="../mac/index.htm"><area shape="rect" coords="255,0,335,97" href="../korn/index.htm"><area shape="rect" coords="337,0,415,109" href="../unixnut/index.htm"><area shape="rect" coords="417,0,512,122" href="../sedawk/index.htm"><area shape="rect" coords="514,0,605,105" href="../lunix/index.htm"><area shape="rect" coords="611,2,694,121" href="../vi/index.htm"> </map></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -