source: chapter09/inputrc.xml@ a3d0817

10.0 10.0-rc1 10.1 10.1-rc1 11.0 11.0-rc1 11.0-rc2 11.0-rc3 ml-11.0 multilib trunk xry111/git-transition xry111/glibc-2.34 xry111/tester-nohack xry111/usr-move
Last change on this file since a3d0817 was a3d0817, checked in by Bruce Dubbs <bdubbs@…>, 18 months ago

Text updated for cross2 chapter 9

git-svn-id: http://svn.linuxfromscratch.org/LFS/branches/cross2@11928 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

  • Property mode set to 100644
File size: 2.6 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-config-inputrc">
9 <?dbhtml filename="inputrc.html"?>
10
11 <title>Creating the /etc/inputrc File</title>
12
13 <indexterm zone="ch-config-inputrc">
14 <primary sortas="e-/etc/inputrc">/etc/inputrc</primary>
15 </indexterm>
16
17 <para>The <filename>inputrc</filename> file is the configuration file for
18 the readline library, which provides editing capabilities while the user is
19 entering a line from the terminal. It works by translating keyboard inputs
20 into specific actions. Readline is used by bash and most other shells as
21 well as many other applications.</para>
22
23 <para>Most people do not need user-specific functionality so the command
24 below creates a global <filename>/etc/inputrc</filename> used by everyone who
25 logs in. If you later decide you need to override the defaults on a per user
26 basis, you can create a <filename>.inputrc</filename> file in the user's home
27 directory with the modified mappings.</para>
28
29 <para>For more information on how to edit the <filename>inputrc</filename>
30 file, see <command>info bash</command> under the <emphasis>Readline Init
31 File</emphasis> section. <command>info readline</command> is also a good
32 source of information.</para>
33
34 <para>Below is a generic global <filename>inputrc</filename> along with comments
35 to explain what the various options do. Note that comments cannot be on the same
36 line as commands. Create the file using the following command:</para>
37
38<screen><userinput>cat &gt; /etc/inputrc &lt;&lt; "EOF"
39<literal># Begin /etc/inputrc
40# Modified by Chris Lynn &lt;roryo@roryo.dynup.net&gt;
41
42# Allow the command prompt to wrap to the next line
43set horizontal-scroll-mode Off
44
45# Enable 8bit input
46set meta-flag On
47set input-meta On
48
49# Turns off 8th bit stripping
50set convert-meta Off
51
52# Keep the 8th bit for display
53set output-meta On
54
55# none, visible or audible
56set bell-style none
57
58# All of the following map the escape sequence of the value
59# contained in the 1st argument to the readline specific functions
60"\eOd": backward-word
61"\eOc": forward-word
62
63# for linux console
64"\e[1~": beginning-of-line
65"\e[4~": end-of-line
66"\e[5~": beginning-of-history
67"\e[6~": end-of-history
68"\e[3~": delete-char
69"\e[2~": quoted-insert
70
71# for xterm
72"\eOH": beginning-of-line
73"\eOF": end-of-line
74
75# for Konsole
76"\e[H": beginning-of-line
77"\e[F": end-of-line
78
79# End /etc/inputrc</literal>
80EOF</userinput></screen>
81
82</sect1>
Note: See TracBrowser for help on using the repository browser.