Automatic commit
[selector.git] / selector.1
1 .TH "SELECTOR" "1"
2 .SH "NAME"
3 selector - A simple shell command for dynamic pattern selection
4 .SH "SYNOPSIS"
5 .PP
6 \fBselector\fP [\fBoptions\fP] -f <filename>
7 .SH "DESCRIPTION"
8 .PP
9 \fBselector\fP is a command line dynamic string selection. A you type
10 a list of strings separated by ';', the display is updated to show
11 only the lines containing all the said strings.
12
13 The main usage of selector is as an efficient search in the shell
14 command history. With the correct option, it will inject the selected
15 line into the virtual tty input buffer, hence allowing the user to
16 edit the line and execute it as a standard command.
17
18 Keys corresponding to ASCII codes between ' ' and '~' add a character
19 to the pattern string. The Delete key, Backspace key, ^D and ^H delete
20 one character from the pattern string.
21
22 The Up and Down cursor keys move the selected line accordingly, and
23 PageUp and PageDown move by ten lines. The Home and End key move to
24 the top and the bottom of the list respectively. The return key
25 selects the current line and quits.
26
27 You can cancel the selection either by interrupting the command with
28 ^C or by typing ^G.
29
30 .SH "OPTIONS"
31 .IP "\fB-h\fP" 10
32 display help and exits
33 .IP "\fB-v\fP" 10
34 inject the selected line into the tty input buffer
35 .IP "\fB-m\fP" 10
36 force the monochrome mode
37 .IP "\fB-t <color fg modeline> <color bg modeline> <color fg highlight> <color bg highlight>\fP" 10
38 select a color them; each color is a positive number
39 .IP "\fB-o <output filename>\fP" 10
40 write the selected line into the specified file
41 .IP "\fB-s <pattern separator>\fP" 10
42 specify the symbol to separate the substrings in the search pattern
43 .IP "\fB-l <max number of lines>\fP" 10
44 specify the maximum number of lines to consider
45 .IP "\fB-f <input filename>\fP" 10
46 specify the file to search into
47
48 .SH "EXAMPLES"
49
50 To use selector to search into your shell history:
51
52 selector -f ${HISTFILE} -v
53
54 .SH "AUTHOR"
55 .PP
56 Written by Francois Fleuret <francois@fleuret.org>. Permission is
57 granted to copy, distribute and/or modify this document under the
58 terms of the GNU GPL.