[ab4fdfc] | 1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
[6732c094] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
[42fc81b] | 3 | "http://www.oasis-open.org/do/xml/4.5/docbookx.dtd" [
|
---|
[44f085a] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[9052373] | 7 | <!-- Following URL does has old versions: https://astron.com/pub/tcsh/old/ -->
|
---|
| 8 | <!ENTITY tcsh-download-http "https://astron.com/pub/tcsh/tcsh-&tcsh-version;.tar.gz">
|
---|
[e1e58be] | 9 | <!ENTITY tcsh-download-ftp " ">
|
---|
[d7d659d] | 10 | <!ENTITY tcsh-md5sum "d7788e78ddf90b6894bc20054414afe1">
|
---|
[f5cfb36] | 11 | <!ENTITY tcsh-size "936 KB">
|
---|
[56250b98] | 12 | <!ENTITY tcsh-buildsize "11 MB (with tests)">
|
---|
[59a6b63] | 13 | <!ENTITY tcsh-time "0.2 SBU (with tests)">
|
---|
[44f085a] | 14 | ]>
|
---|
| 15 |
|
---|
[0b5a693] | 16 | <sect1 id="tcsh" xreflabel="Tcsh-&tcsh-version;">
|
---|
[eab549f] | 17 | <?dbhtml filename="tcsh.html"?>
|
---|
| 18 |
|
---|
| 19 | <title>Tcsh-&tcsh-version;</title>
|
---|
| 20 |
|
---|
| 21 | <indexterm zone="tcsh">
|
---|
| 22 | <primary sortas="a-Tcsh">Tcsh</primary>
|
---|
| 23 | </indexterm>
|
---|
| 24 |
|
---|
| 25 | <sect2 role="package">
|
---|
| 26 | <title>Introduction to Tcsh</title>
|
---|
| 27 |
|
---|
[f716ef4] | 28 | <para>
|
---|
| 29 | The <application>Tcsh</application> package contains <quote>an
|
---|
| 30 | enhanced but completely compatible version of the Berkeley Unix C shell
|
---|
| 31 | (<command>csh</command>)</quote>. This is useful as an alternative shell
|
---|
| 32 | for those who prefer C syntax to that of the <command>bash</command>
|
---|
| 33 | shell, and also because some programs require the C shell in order to
|
---|
| 34 | perform installation tasks.
|
---|
| 35 | </para>
|
---|
[fd7e0ed6] | 36 |
|
---|
[868811b] | 37 | &lfs121_checked;
|
---|
[eab549f] | 38 |
|
---|
| 39 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 40 | <itemizedlist spacing="compact">
|
---|
| 41 | <listitem>
|
---|
[f716ef4] | 42 | <para>
|
---|
| 43 | Download (HTTP): <ulink url="&tcsh-download-http;"/>
|
---|
| 44 | </para>
|
---|
[eab549f] | 45 | </listitem>
|
---|
| 46 | <listitem>
|
---|
[f716ef4] | 47 | <para>
|
---|
| 48 | Download (FTP): <ulink url="&tcsh-download-ftp;"/>
|
---|
| 49 | </para>
|
---|
[eab549f] | 50 | </listitem>
|
---|
| 51 | <listitem>
|
---|
[f716ef4] | 52 | <para>
|
---|
| 53 | Download MD5 sum: &tcsh-md5sum;
|
---|
| 54 | </para>
|
---|
[eab549f] | 55 | </listitem>
|
---|
| 56 | <listitem>
|
---|
[f716ef4] | 57 | <para>
|
---|
| 58 | Download size: &tcsh-size;
|
---|
| 59 | </para>
|
---|
[eab549f] | 60 | </listitem>
|
---|
| 61 | <listitem>
|
---|
[f716ef4] | 62 | <para>
|
---|
| 63 | Estimated disk space required: &tcsh-buildsize;
|
---|
| 64 | </para>
|
---|
[eab549f] | 65 | </listitem>
|
---|
| 66 | <listitem>
|
---|
[f716ef4] | 67 | <para>
|
---|
| 68 | Estimated build time: &tcsh-time;
|
---|
| 69 | </para>
|
---|
[eab549f] | 70 | </listitem>
|
---|
| 71 | </itemizedlist>
|
---|
| 72 |
|
---|
| 73 | </sect2>
|
---|
| 74 |
|
---|
| 75 | <sect2 role="installation">
|
---|
| 76 | <title>Installation of Tcsh</title>
|
---|
[59a6b63] | 77 |
|
---|
[f716ef4] | 78 | <para>
|
---|
| 79 | Install <application>Tcsh</application> by running the following
|
---|
| 80 | commands:
|
---|
| 81 | </para>
|
---|
[eab549f] | 82 |
|
---|
[01e9d327] | 83 | <screen><userinput>./configure --prefix=/usr &&
|
---|
[78d8214e] | 84 | make</userinput></screen>
|
---|
[2956bc0] | 85 |
|
---|
[f716ef4] | 86 | <para>
|
---|
| 87 | To test the results, issue: <command>make check</command>.
|
---|
| 88 | </para>
|
---|
[eab549f] | 89 |
|
---|
[f716ef4] | 90 | <para>
|
---|
| 91 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 92 | </para>
|
---|
[eab549f] | 93 |
|
---|
[f70c31f] | 94 | <screen role="root"><userinput>make install install.man &&
|
---|
[59a6b63] | 95 |
|
---|
[f70c31f] | 96 | ln -v -sf tcsh /bin/csh &&
|
---|
[78d8214e] | 97 | ln -v -sf tcsh.1 /usr/share/man/man1/csh.1</userinput></screen>
|
---|
| 98 | <!--
|
---|
[f1d3e56] | 99 | install -v -m755 -d /usr/share/doc/tcsh-&tcsh-version;/html &&
|
---|
[2956bc0] | 100 | install -v -m644 tcsh.html/* /usr/share/doc/tcsh-&tcsh-version;/html &&
|
---|
[f70c31f] | 101 | install -v -m644 FAQ /usr/share/doc/tcsh-&tcsh-version;</userinput></screen>
|
---|
[78d8214e] | 102 | -->
|
---|
[eab549f] | 103 | </sect2>
|
---|
| 104 |
|
---|
| 105 | <sect2 role="commands">
|
---|
| 106 | <title>Command Explanations</title>
|
---|
[f45b1953] | 107 |
|
---|
[78d8214e] | 108 | <!-- No longer there
|
---|
[f716ef4] | 109 | <para>
|
---|
| 110 | <command>sh ./tcsh.man2html</command>: This creates HTML documentation
|
---|
| 111 | from the formatted man page.
|
---|
| 112 | </para>
|
---|
[78d8214e] | 113 | -->
|
---|
[f716ef4] | 114 | <para>
|
---|
| 115 | <command>ln -v -sf tcsh /bin/csh</command>: The FHS states that if
|
---|
| 116 | there is a <application>C</application> shell installed, there should
|
---|
| 117 | be a symlink from <filename>/bin/csh</filename> to it. This creates
|
---|
| 118 | that symlink.
|
---|
| 119 | </para>
|
---|
[eab549f] | 120 |
|
---|
| 121 | </sect2>
|
---|
| 122 |
|
---|
| 123 | <sect2 role="configuration">
|
---|
| 124 | <title>Configuring Tcsh</title>
|
---|
| 125 |
|
---|
| 126 | <sect3 id="tcsh-config">
|
---|
| 127 | <title>Config Files</title>
|
---|
| 128 |
|
---|
[f716ef4] | 129 | <para>
|
---|
| 130 | There are numerous configuration files for the C shell. Examples
|
---|
| 131 | of these are <filename>/etc/csh.cshrc</filename>,
|
---|
| 132 | <filename>/etc/csh.login</filename>,
|
---|
| 133 | <filename>/etc/csh.logout</filename>,
|
---|
| 134 | <filename>~/.tcshrc</filename>, <filename>~/.cshrc</filename>,
|
---|
| 135 | <filename>~/.history</filename>, <filename>~/.cshdirs</filename>,
|
---|
| 136 | <filename>~/.login</filename>, and <filename>~/.logout</filename>. More
|
---|
| 137 | information on these files can be found in the
|
---|
[fedbe2f] | 138 | <ulink role='man' url='&man;tcsh.1'>tcsh(1)</ulink> man page.
|
---|
[f716ef4] | 139 | </para>
|
---|
[eab549f] | 140 |
|
---|
| 141 | <indexterm zone="tcsh tcsh-config">
|
---|
| 142 | <primary sortas="e-etc-csh.cshrc">/etc/csh.cshrc</primary>
|
---|
| 143 | </indexterm>
|
---|
| 144 |
|
---|
| 145 | <indexterm zone="tcsh tcsh-config">
|
---|
| 146 | <primary sortas="e-etc-csh.login">/etc/csh.login</primary>
|
---|
| 147 | </indexterm>
|
---|
| 148 |
|
---|
| 149 | <indexterm zone="tcsh tcsh-config">
|
---|
| 150 | <primary sortas="e-etc-csh.logout">/etc/csh.logout</primary>
|
---|
| 151 | </indexterm>
|
---|
| 152 |
|
---|
| 153 | <indexterm zone="tcsh tcsh-config">
|
---|
| 154 | <primary sortas="e-AA.tcshrc">~/.tcshrc</primary>
|
---|
| 155 | </indexterm>
|
---|
| 156 |
|
---|
| 157 | <indexterm zone="tcsh tcsh-config">
|
---|
| 158 | <primary sortas="e-AA.cshrc">~/.cshrc</primary>
|
---|
| 159 | </indexterm>
|
---|
| 160 |
|
---|
| 161 | <indexterm zone="tcsh tcsh-config">
|
---|
| 162 | <primary sortas="e-AA.history">~/.history</primary>
|
---|
| 163 | </indexterm>
|
---|
| 164 |
|
---|
| 165 | <indexterm zone="tcsh tcsh-config">
|
---|
| 166 | <primary sortas="e-AA.cshdirs">~/.cshdirs</primary>
|
---|
| 167 | </indexterm>
|
---|
[42e6981] | 168 |
|
---|
[eab549f] | 169 | <indexterm zone="tcsh tcsh-config">
|
---|
| 170 | <primary sortas="e-AA.login">~/.login</primary>
|
---|
| 171 | </indexterm>
|
---|
| 172 |
|
---|
| 173 | <indexterm zone="tcsh tcsh-config">
|
---|
| 174 | <primary sortas="e-AA.logout">~/.logout</primary>
|
---|
| 175 | </indexterm>
|
---|
| 176 |
|
---|
| 177 | </sect3>
|
---|
| 178 |
|
---|
[2956bc0] | 179 | <sect3>
|
---|
| 180 | <title>Configuration Information</title>
|
---|
| 181 |
|
---|
[f716ef4] | 182 | <para>
|
---|
| 183 | Update <filename>/etc/shells</filename> to include the C shell
|
---|
[78d8214e] | 184 | program names (as the &root; user):
|
---|
[f716ef4] | 185 | </para>
|
---|
[2956bc0] | 186 |
|
---|
| 187 | <screen role="root"><userinput>cat >> /etc/shells << "EOF"
|
---|
| 188 | <literal>/bin/tcsh
|
---|
| 189 | /bin/csh</literal>
|
---|
[59a6b63] | 190 | EOF</userinput></screen>
|
---|
| 191 |
|
---|
| 192 | <para>
|
---|
| 193 | The following <filename>~/.cshrc</filename> provides two alternative
|
---|
| 194 | colour prompts and coloured <command>ls</command> output. If you prefer
|
---|
[78d8214e] | 195 | a global modification, issue the command as the &root; user, replacing
|
---|
[59a6b63] | 196 | <filename>~/.cshrc</filename> by <filename>/etc/csh.cshrc</filename>.
|
---|
| 197 | </para>
|
---|
| 198 |
|
---|
| 199 | <screen><userinput>cat > ~/.cshrc << "EOF"
|
---|
| 200 | <literal># Original at:
|
---|
| 201 | # https://www.cs.umd.edu/~srhuang/teaching/code_snippets/prompt_color.tcsh.html
|
---|
| 202 |
|
---|
[077d95b] | 203 | # Modified by the BLFS Development Team.
|
---|
[59a6b63] | 204 |
|
---|
| 205 | # Add these lines to your ~/.cshrc (or to /etc/csh.cshrc).
|
---|
| 206 |
|
---|
| 207 | # Colors!
|
---|
| 208 | set red="%{\033[1;31m%}"
|
---|
| 209 | set green="%{\033[0;32m%}"
|
---|
| 210 | set yellow="%{\033[1;33m%}"
|
---|
| 211 | set blue="%{\033[1;34m%}"
|
---|
| 212 | set magenta="%{\033[1;35m%}"
|
---|
| 213 | set cyan="%{\033[1;36m%}"
|
---|
| 214 | set white="%{\033[0;37m%}"
|
---|
| 215 | set end="%{\033[0m%}" # This is needed at the end...
|
---|
| 216 |
|
---|
| 217 | # Setting the actual prompt. Two separate versions for you to try, pick
|
---|
| 218 | # whichever one you like better, and change the colors as you want.
|
---|
| 219 | # Just don't mess with the ${end} guy in either line... Comment out or
|
---|
| 220 | # delete the prompt you don't use.
|
---|
| 221 |
|
---|
| 222 | set prompt="${green}%n${blue}@%m ${white}%~ ${green}%%${end} "
|
---|
| 223 | set prompt="[${green}%n${blue}@%m ${white}%~ ]${end} "
|
---|
| 224 |
|
---|
| 225 | # This was not in the original URL above
|
---|
| 226 | # Provides coloured ls
|
---|
| 227 | alias ls ls --color=always
|
---|
| 228 |
|
---|
| 229 | # Clean up after ourselves...
|
---|
| 230 | unset red green yellow blue magenta cyan yellow white end</literal>
|
---|
[2956bc0] | 231 | EOF</userinput></screen>
|
---|
| 232 |
|
---|
| 233 | </sect3>
|
---|
| 234 |
|
---|
[eab549f] | 235 | </sect2>
|
---|
| 236 |
|
---|
| 237 | <sect2 role="content">
|
---|
| 238 | <title>Contents</title>
|
---|
| 239 |
|
---|
| 240 | <segmentedlist>
|
---|
| 241 | <segtitle>Installed Program</segtitle>
|
---|
| 242 | <segtitle>Installed Libraries</segtitle>
|
---|
[2956bc0] | 243 | <segtitle>Installed Directory</segtitle>
|
---|
[eab549f] | 244 |
|
---|
| 245 | <seglistitem>
|
---|
| 246 | <seg>tcsh</seg>
|
---|
| 247 | <seg>None</seg>
|
---|
[78d8214e] | 248 | <seg>None <!--/usr/share/doc/tcsh-&tcsh-version;--></seg>
|
---|
[eab549f] | 249 | </seglistitem>
|
---|
| 250 | </segmentedlist>
|
---|
| 251 |
|
---|
| 252 | <variablelist>
|
---|
| 253 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 254 | <?dbfo list-presentation="list"?>
|
---|
| 255 | <?dbhtml list-presentation="table"?>
|
---|
| 256 |
|
---|
| 257 | <varlistentry id="tcsh-prog">
|
---|
| 258 | <term><command>tcsh</command></term>
|
---|
| 259 | <listitem>
|
---|
[f716ef4] | 260 | <para>
|
---|
| 261 | is an enhanced but completely compatible version of the
|
---|
| 262 | Berkeley Unix C shell, <command>csh</command>. It is usable as
|
---|
[4c24eb0a] | 263 | both an interactive shell and a script processor
|
---|
[f716ef4] | 264 | </para>
|
---|
[eab549f] | 265 | <indexterm zone="tcsh tcsh-prog">
|
---|
| 266 | <primary sortas="b-tcsh">tcsh</primary>
|
---|
| 267 | </indexterm>
|
---|
| 268 | </listitem>
|
---|
| 269 | </varlistentry>
|
---|
| 270 | </variablelist>
|
---|
| 271 |
|
---|
| 272 | </sect2>
|
---|
| 273 |
|
---|
| 274 | </sect1>
|
---|