1PICK(1) BSD General Commands Manual PICK(1)
2
4 pick — fuzzy select anything
5
7 pick [-dKoSXx] [-q query]
8
10 The pick utility allows users to select from a set of choices using an
11 curses(3) interface with fuzzy search functionality.
12
13 The choices are read from stdin, and the selected choice written to
14 stdout.
15
16 The options are as follows:
17
18 -d Read and display descriptions. Input lines will be split into
19 two parts by the last occurrence of IFS. Both parts will be
20 displayed but only the first part will be used when searching.
21
22 -K Disable toggling of keypad transmit mode. Useful when running
23 pick from within another interactive program which already has
24 set the correct transmit mode.
25
26 -o Output description of selected choice on exit.
27
28 -q query Supply an initial search query.
29
30 -S Disable sorting. Only filter the choices instead of addition‐
31 ally sorting by score. This option can be toggled from within
32 the interface, see COMMANDS.
33
34 -x Enable the use of the alternate screen terminal feature. This
35 is the default.
36
37 -X Disable the use of the alternate screen terminal feature.
38
40 Ctrl-C
41 Exit with a erroneous status without outputting the selected
42 choice. While this command often being defined as Ctrl-C it is de‐
43 termined by the VINTR control character, see termios(4).
44
45 Ctrl-L
46 Redraw interface with respect to the current size of the terminal.
47
48 Ctrl-O
49 Toggle sorting.
50
51 Up/Down | Ctrl-P/Ctrl-N
52 Select between choices matching the current search query.
53
54 Page-Down/Page-Up | Ctrl-V/Alt-V | Alt-Space
55 Move the selection to the choice located one page down/up from the
56 currently selected choice.
57
58 Home/End | Alt-</Alt->
59 Move the selection to the first/last choice matching the current
60 search query.
61
62 Enter
63 Output the currently selected choice and exit.
64
65 Alt-Enter
66 Output the current input query and exit.
67
68 Left/Right | Ctrl-B/Ctrl-F
69 Move the cursor left and right in the search query input field.
70
71 Ctrl-A
72 Move the cursor to the beginning of the line in the search query
73 input field.
74
75 Ctrl-E
76 Move the cursor to the end of the line in the search query input
77 field.
78
79 Backspace | Ctrl-H
80 Delete one character to the left of the cursor in the search query
81 input field.
82
83 Delete | Ctrl-D
84 Delete the character under the cursor in the search query input
85 field.
86
87 Ctrl-W | Alt-Backspace
88 Delete the word to the left of the cursor. A word is recognized as
89 a sequence of characters for which either isalnum(3) is true or the
90 character is an underscore.
91
92 Ctrl-U
93 Delete to the beginning of the line in the search query input
94 field.
95
96 Ctrl-K
97 Delete to the end of the line in the search query input field.
98
99 Printable characters
100 Added to the search query and will refine the current search.
101
103 The following environment variables will affect the execution of pick:
104
105 IFS Determines the separator used between choices and descriptions.
106
108 SIGWINCH The screen is resized.
109
111 Select a file in the current directory to open using xdg-open(1):
112
113 $ find . -type f | pick | xargs xdg-open
114
115 Select a command from the history to execute:
116
117 $ eval $(fc -ln 1 | pick)
118
120 The pick utility exits 0 on success, and >0 if an error occurs.
121
123 The first version of pick was released on August 18, 2014. Development
124 was sponsored by thoughtbot: https://thoughtbot.com from the start of the
125 project until September 2016.
126
128 Calle Erlandsson <calle@calleerlandsson.com>
129 Anton Lindqvist <anton@basename.se>
130
131BSD August 17, 2014 BSD