1October 18, 2003()                                          October 18, 2003()
2
3
4

NAME

6       editrc - configuration file for editline library
7

SYNOPSIS

9       editrc
10

DESCRIPTION

12       The  editrc file defines various settings to be used by the editline(3)
13       library.
14
15       The format of each line is: [prog:]command [arg [...]]
16
17       command is one of the editline(3) builtin commands.  Refer  to  BUILTIN
18       COMMANDS for more information.
19
20       prog  is  the  program name string that a program defines when it calls
21       el_init(3) to set up editline(3), which is  usually  argv[0].   command
22       will be executed for any program which matches prog.
23
24       prog  may  also  be  a regex(3) style regular expression, in which case
25       command will be executed for  any  program  that  matches  the  regular
26       expression.
27
28       If prog is absent, command is executed for all programs.
29

BUILTIN COMMANDS

31       The  editline  library  has some builtin commands, which affect the way
32       that the line editing and history functions operate.  These  are  based
33       on similar named builtins present in the tcsh(1) shell.
34
35       The following builtin commands are available:
36
37       bind   [-a] [-e] [-k] [-l] [-r] [-s] [-v] [key [command]
38
39              Without  options, list all bound keys, and the editor command to
40              which each is bound.  If key is supplied, show the bindings  for
41              key.   If key command is supplied, bind command to key.  Options
42              include:
43
44              -e     Bind all keys to the standard GNU Emacs-like bindings.
45
46              -v     Bind all keys to the standard vi(1) -like bindings.
47
48              -a     List or change key bindings in the vi(1)  mode  alternate
49                     (command mode) key map.
50
51              -k     key  is  interpreted  as a symbolic arrow key name, which
52                     may be one of `up', `down', `left' or `right'.
53
54              -l     List all editor commands and a short description of each.
55
56              -r     Remove a key's binding.
57
58              -s     command is taken as a literal string and treated as  ter‐
59                     minal input when key is typed.  Bound keys in command are
60                     themselves reinterpreted, and this continues for ten lev‐
61                     els of interpretation.
62
63       command may be one of the commands documented in EDITOR COMMANDS below,
64       or another key.
65
66       key and command can contain control characters of the form `^character'
67       ( e.g.  `^A' ), and the following backslashed escape sequences:
68
69
70              \a     Bell
71
72              \b     Backspace
73
74              \e     Escape
75
76              \f     Formfeed
77
78              \n     Newline
79
80              \r     Carriage return
81
82              \t     Horizontal tab
83
84              \v     Vertical tab
85
86              \nnn   The  ASCII  character  corresponding  to the octal number
87                     nnn.
88
89       `\' nullifies the special meaning of the following character, if it has
90       any, notably `\' and `^'.
91
92       echotc [-sv] arg ...
93
94              Exercise  terminal  capabilities  given  in  arg ....  If arg is
95              `baud', `cols', `lines', `rows', `meta' or `tabs', the value  of
96              that  capability  is  printed, with ``yes'' or ``no'' indicating
97              that the terminal does or does not have that capability.
98
99              -s returns an empty string for non-existent capabilities, rather
100              than causing an error.  -v causes messages to be verbose.
101
102       edit [on | off]
103              Enable or disable the editline functionality in a program.
104
105       history list | size n | unique n
106              The  list  command  lists  all entries in the history.  The size
107              command sets the history size to n entries.  The unique  command
108              controls  if history should keep duplicate entries.  If n is non
109              zero, only keep unique history entries.  If n is zero, then keep
110              all entries (the default).
111
112       telltc List  the  values  of  all  the terminal capabilities (see term‐
113              cap(5)) .
114
115       settc cap val
116              Set the terminal capability cap to  val,  as  defined  in  term‐
117              cap(5).  No sanity checking is done.
118
119       setty  [-a] [-d] [-q] [-x] [+mode] [-mode] [mode] [char=c]
120
121              Control  which  tty  modes  that  editrc won't allow the user to
122              change.  -d, -q or -x tells setty to act on the `edit',  `quote'
123              or `execute' set of tty modes respectively; defaulting to -x.
124
125              Without other arguments, setty lists the modes in the chosen set
126              which are fixed on ( `+mode' ) or off ( `-mode' ).  -a lists all
127              tty  modes  in  the  chosen set regardless of the setting.  With
128              +mode, -mode or mode, fixes mode on or off or removes control of
129              mode in the chosen set.
130
131              Setty  can also be used to set tty characters to particular val‐
132              ues using char=value.  If value is empty then the  character  is
133              set to _POSIX_VDISABLE .
134

EDITOR COMMANDS

136       The following editor commands are available for use in key bindings:
137
138       vi-paste-next
139              Vi paste previous deletion to the right of the cursor.
140
141       vi-paste-prev
142              Vi paste previous deletion to the left of the cursor.
143
144       vi-prev-space-word
145              Vi move to the previous space delimited word.
146
147       vi-prev-word
148              Vi move to the previous word.
149
150       vi-next-space-word
151              Vi move to the next space delimited word.
152
153       vi-next-word
154              Vi move to the next word.
155
156       vi-change-case
157              Vi  change  case  of  character under the cursor and advance one
158              character.
159
160       vi-change-meta
161              Vi change prefix command.
162
163       vi-insert-at-bol
164              Vi enter insert mode at the beginning of line.
165
166       vi-replace-char
167              Vi replace character under the cursor with  the  next  character
168              typed.
169
170       vi-replace-mode
171              Vi enter replace mode.
172
173       vi-substitute-char
174              Vi replace character under the cursor and enter insert mode.
175
176       vi-substitute-line
177              Vi substitute entire line.
178
179       vi-change-to-eol
180              Vi change to end of line.
181
182       vi-insert
183              Vi enter insert mode.
184
185       vi-add Vi enter insert mode after the cursor.
186
187       vi-add-at-eol
188              Vi enter insert mode at end of line.
189
190       vi-delete-meta
191              Vi delete prefix command.
192
193       vi-end-word
194              Vi move to the end of the current space delimited word.
195
196       vi-to-end-word
197              Vi move to the end of the current word.
198
199       vi-undo
200              Vi undo last change.
201
202       vi-command-mode
203              Vi enter command mode (use alternative key bindings).
204
205       vi-zero
206              Vi move to the beginning of line.
207
208       vi-delete-prev-char
209              Vi move to previous character (backspace).
210
211       vi-list-or-eof
212              Vi  list choices for completion or indicate end of file if empty
213              line.
214
215       vi-kill-line-prev
216              Vi cut from beginning of line to cursor.
217
218       vi-search-prev
219              Vi search history previous.
220
221       vi-search-next
222              Vi search history next.
223
224       vi-repeat-search-next
225              Vi repeat current search in the same search direction.
226
227       vi-repeat-search-prev
228              Vi repeat current search in the opposite search direction.
229
230       vi-next-char
231              Vi move to the character specified next.
232
233       vi-prev-char
234              Vi move to the character specified previous.
235
236       vi-to-next-char
237              Vi move up to the character specified next.
238
239       vi-to-prev-char
240              Vi move up to the character specified previous.
241
242       vi-repeat-next-char
243              Vi repeat current character search in the same search direction.
244
245       vi-repeat-prev-char
246              Vi repeat current character search in the opposite search direc‐
247              tion.
248
249       em-delete-or-list
250              Delete  character  under cursor or list completions if at end of
251              line.
252
253       em-delete-next-word
254              Cut from cursor to end of current word.
255
256       em-yank
257              Paste cut buffer at cursor position.
258
259       em-kill-line
260              Cut the entire line and save in cut buffer.
261
262       em-kill-region
263              Cut area between mark and cursor and save in cut buffer.
264
265       em-copy-region
266              Copy area between mark and cursor to cut buffer.
267
268       em-gosmacs-transpose
269              Exchange the two characters before the cursor.
270
271       em-next-word
272              Move next to end of current word.
273
274       em-upper-case
275              Uppercase the characters from cursor to end of current word.
276
277       em-capitol-case
278              Capitalize the characters from cursor to end of current word.
279
280       em-lower-case
281              Lowercase the characters from cursor to end of current word.
282
283       em-set-mark
284              Set the mark at cursor.
285
286       em-exchange-mark
287              Exchange the cursor and mark.
288
289       em-universal-argument
290              Universal argument (argument times 4).
291
292       em-meta-next
293              Add 8th bit to next character typed.
294
295       em-toggle-overwrite
296              Switch from insert to overwrite mode or vice versa.
297
298       em-copy-prev-word
299              Copy current word to cursor.
300
301       em-inc-search-next
302              Emacs incremental next search.
303
304       em-inc-search-prev
305              Emacs incremental reverse search.
306
307       ed-end-of-file
308              Indicate end of file.
309
310       ed-insert
311              Add character to the line.
312
313       ed-delete-prev-word
314              Delete from beginning of current word to cursor.
315
316       ed-delete-next-char
317              Delete character under cursor.
318
319       ed-kill-line
320              Cut to the end of line.
321
322       ed-move-to-end
323              Move cursor to the end of line.
324
325       ed-move-to-beg
326              Move cursor to the beginning of line.
327
328       ed-transpose-chars
329              Exchange the character to the left of the cursor  with  the  one
330              under it.
331
332       ed-next-char
333              Move to the right one character.
334
335       ed-prev-word
336              Move to the beginning of the current word.
337
338       ed-prev-char
339              Move to the left one character.
340
341       ed-quoted-insert
342              Add the next character typed verbatim.
343
344       ed-digit
345              Adds to argument or enters a digit.
346
347       ed-argument-digit
348              Digit that starts argument.
349
350       ed-unassigned
351              Indicates unbound character.
352
353       ed-tty-sigint
354              Tty interrupt character.
355
356       ed-tty-dsusp
357              Tty delayed suspend character.
358
359       ed-tty-flush-output
360              Tty flush output characters.
361
362       ed-tty-sigquit
363              Tty quit character.
364
365       ed-tty-sigtstp
366              Tty suspend character.
367
368       ed-tty-stop-output
369              Tty disallow output characters.
370
371       ed-tty-start-output
372              Tty allow output characters.
373
374       ed-newline
375              Execute command.
376
377       ed-delete-prev-char
378              Delete the character to the left of the cursor.
379
380       ed-clear-screen
381              Clear screen leaving current line at the top.
382
383       ed-redisplay
384              Redisplay everything.
385
386       ed-start-over
387              Erase current line and start from scratch.
388
389       ed-sequence-lead-in
390              First character in a bound sequence.
391
392       ed-prev-history
393              Move to the previous history line.
394
395       ed-next-history
396              Move to the next history line.
397
398       ed-search-prev-history
399              Search previous in history for a line matching the current.
400
401       ed-search-next-history
402              Search next in history for a line matching the current.
403
404       ed-prev-line
405              Move up one line.
406
407       ed-next-line
408              Move down one line.
409
410       ed-command
411              Editline extended command.
412

SEE ALSO

414       editline(3), regex(3), termcap(5)
415

AUTHORS

417       The  editline  library  was written by Christos Zoulas, and this manual
418       was written by Luke Mewburn, with some sections inspired by tcsh(1).
419
420
421
422                                                            October 18, 2003()
Impressum