Lines Matching +refs:csh +refs:line +refs:to +refs:string
2 This file documents the user interface to the GNU History library.
7 Permission is granted to make and distribute verbatim copies of this manual
11 Permission is granted to process this file through Tex and print the
13 identical to this one except for the removal of this paragraph (this
14 paragraph not being relevant to the printed manual).
16 Permission is granted to copy and distribute modified versions of this
18 GNU Copyright statement is available to the distributee, and provided that
20 permission notice identical to this one.
22 Permission is granted to copy and distribute translations of this manual
35 This chapter describes how to use the @sc{gnu} History Library
42 This chapter describes how to use the @sc{gnu} History Library interactively,
70 When the @option{-o history} option to the @code{set} builtin
72 the shell provides access to the @dfn{command history},
75 number of commands to save in a history list.
78 The shell stores each command in the history list prior to
80 but after history expansion is performed, subject to the
87 necessary, to contain no more than the number of lines specified by
90 @env{$HISTSIZE} lines are copied from the history list to the file
93 the lines are appended to the history file,
98 to contain no more than @env{$HISTFILESIZE}
102 associated with each history entry is written to the history file,
106 as timestamps for the previous history line.
108 The builtin command @code{fc} may be used to list or edit and re-execute
110 The @code{history} builtin may be used to display or modify the history
112 When using command-line editing, search commands
113 are available in each editing mode that provide access to the
118 variables may be set to cause the shell to save only a subset of the
121 shell option, if enabled, causes the shell to attempt to save each
122 line of a multi-line command in the same history entry, adding
123 semicolons where necessary to preserve syntactic correctness.
125 shell option causes the shell to save the command with embedded newlines
127 The @code{shopt} builtin is used to set these options.
146 Fix Command. In the first form, a range of commands from @var{first} to
148 @var{last} may be specified as a string (to locate the most recent
149 command beginning with that string) or as a number (an index into the
151 current command number). If @var{last} is not specified it is set to
152 @var{first}. If @var{first} is not specified it is set to the previous
159 is used: @code{$@{FCEDIT:-$@{EDITOR:-vi@}@}}. This says to use the
167 A useful alias to use with the @code{fc} command is @code{r='fc -s'}, so
181 With no options, display the history list with line numbers.
185 it is used as a format string for @var{strftime} to display
188 and the history line.
195 with the other options to replace the history list completely.
205 current Bash session) to the history file.
209 to the current history list. These are lines appended to the history
213 Read the current history file and append its contents to
217 Write out the current history to the history file.
224 The @var{arg}s are added to the end of
242 to the history expansion provided by @code{csh}. This section
243 describes the syntax used to manipulate the history information.
246 the input stream, making it easy to repeat commands, insert the
247 arguments to a previous command into the current input line, or
250 History expansion takes place in two parts. The first is to determine
251 which line from the history list should be used during substitution.
252 The second is to select portions of that line for inclusion into the
253 current one. The line selected from the history is called the
254 @dfn{event}, and the portions of that line that are acted upon are
255 called @dfn{words}. Various @dfn{modifiers} are available to manipulate
256 the selected words. The line is broken into words in the same fashion
262 Only @samp{\} and @samp{'} may be used to escape the history expansion
268 builtin (@pxref{Bash Builtins}) may be used to tailor
271 is being used, history substitutions are not immediately passed to
273 Instead, the expanded line is reloaded into the Readline
278 The @option{-p} option to the @code{history} builtin command
279 may be used to see what a history expansion will do before using it.
280 The @option{-s} option to the @code{history} builtin may be used to
281 add commands to the end of the history list without actually executing
288 the history comment character to mark history timestamps when
293 * Event Designators:: How to specify which history line to use.
302 An event designator is a reference to a command line entry in the
304 Unless the reference is absolute, events are relative to the current
313 the end of the line, @samp{=} or @samp{(} (when the
318 the end of the line, or @samp{=}.
322 Refer to command line @var{n}.
325 Refer to the command @var{n} lines back.
328 Refer to the previous command. This is a synonym for @samp{!-1}.
330 @item @code{!@var{string}}
331 Refer to the most recent command
333 starting with @var{string}.
335 @item @code{!?@var{string}[?]}
336 Refer to the most recent command
338 containing @var{string}.
340 @samp{?} may be omitted if the @var{string} is followed immediately by
345 with @var{string2}. Equivalent to
349 The entire command line typed so far.
356 Word designators are used to select desired words from the event.
360 of the line, with the first word being denoted by 0 (zero). Words are
361 inserted into the current line separated by single spaces.
373 shortened to @code{!$}.
398 The word matched by the most recent @samp{?@var{string}?} search.
405 It is not an error to use @samp{*} if there is just one word in the event;
406 the empty string is returned in that case.
454 event line. Any delimiter may be used in place of @samp{/}.
459 character on the input line.
466 Cause changes to be applied over the entire event line. Used in
471 Apply the following @samp{s} modifier once to each word in the event.