If you can read this on Debian, you're living in the future
[ranger.git] / doc / ranger.1
bloba33252e2b2a6aee93b9a4ed1f496c8958821dee3
1 .\" Automatically generated by Pod::Man 4.10 (Pod::Simple 3.35)
2 .\"
3 .\" Standard preamble:
4 .\" ========================================================================
5 .de Sp \" Vertical space (when we can't use .PP)
6 .if t .sp .5v
7 .if n .sp
8 ..
9 .de Vb \" Begin verbatim text
10 .ft CW
11 .nf
12 .ne \\$1
14 .de Ve \" End verbatim text
15 .ft R
16 .fi
18 .\" Set up some character translations and predefined strings.  \*(-- will
19 .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
20 .\" double quote, and \*(R" will give a right double quote.  \*(C+ will
21 .\" give a nicer C++.  Capital omega is used to do unbreakable dashes and
22 .\" therefore won't be available.  \*(C` and \*(C' expand to `' in nroff,
23 .\" nothing in troff, for use with C<>.
24 .tr \(*W-
25 .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
26 .ie n \{\
27 .    ds -- \(*W-
28 .    ds PI pi
29 .    if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
30 .    if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\"  diablo 12 pitch
31 .    ds L" ""
32 .    ds R" ""
33 .    ds C` ""
34 .    ds C' ""
35 'br\}
36 .el\{\
37 .    ds -- \|\(em\|
38 .    ds PI \(*p
39 .    ds L" ``
40 .    ds R" ''
41 .    ds C`
42 .    ds C'
43 'br\}
44 .\"
45 .\" Escape single quotes in literal strings from groff's Unicode transform.
46 .ie \n(.g .ds Aq \(aq
47 .el       .ds Aq '
48 .\"
49 .\" If the F register is >0, we'll generate index entries on stderr for
50 .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
51 .\" entries marked with X<> in POD.  Of course, you'll have to process the
52 .\" output yourself in some meaningful fashion.
53 .\"
54 .\" Avoid warning from groff about undefined register 'F'.
55 .de IX
57 .nr rF 0
58 .if \n(.g .if rF .nr rF 1
59 .if (\n(rF:(\n(.g==0)) \{\
60 .    if \nF \{\
61 .        de IX
62 .        tm Index:\\$1\t\\n%\t"\\$2"
64 .        if !\nF==2 \{\
65 .            nr % 0
66 .            nr F 2
67 .        \}
68 .    \}
69 .\}
70 .rr rF
71 .\"
72 .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
73 .\" Fear.  Run.  Save yourself.  No user-serviceable parts.
74 .    \" fudge factors for nroff and troff
75 .if n \{\
76 .    ds #H 0
77 .    ds #V .8m
78 .    ds #F .3m
79 .    ds #[ \f1
80 .    ds #] \fP
81 .\}
82 .if t \{\
83 .    ds #H ((1u-(\\\\n(.fu%2u))*.13m)
84 .    ds #V .6m
85 .    ds #F 0
86 .    ds #[ \&
87 .    ds #] \&
88 .\}
89 .    \" simple accents for nroff and troff
90 .if n \{\
91 .    ds ' \&
92 .    ds ` \&
93 .    ds ^ \&
94 .    ds , \&
95 .    ds ~ ~
96 .    ds /
97 .\}
98 .if t \{\
99 .    ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
100 .    ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
101 .    ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
102 .    ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
103 .    ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
104 .    ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
106 .    \" troff and (daisy-wheel) nroff accents
107 .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
108 .ds 8 \h'\*(#H'\(*b\h'-\*(#H'
109 .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
110 .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
111 .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
112 .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
113 .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
114 .ds ae a\h'-(\w'a'u*4/10)'e
115 .ds Ae A\h'-(\w'A'u*4/10)'E
116 .    \" corrections for vroff
117 .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
118 .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
119 .    \" for low resolution devices (crt and lpr)
120 .if \n(.H>23 .if \n(.V>19 \
122 .    ds : e
123 .    ds 8 ss
124 .    ds o a
125 .    ds d- d\h'-1'\(ga
126 .    ds D- D\h'-1'\(hy
127 .    ds th \o'bp'
128 .    ds Th \o'LP'
129 .    ds ae ae
130 .    ds Ae AE
132 .rm #[ #] #H #V #F C
133 .\" ========================================================================
135 .IX Title "RANGER 1"
136 .TH RANGER 1 "ranger-1.9.2" "2018-09-09" "ranger manual"
137 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
138 .\" way too many mistakes in technical documents.
139 .if n .ad l
141 .SH "NAME"
142 ranger \- visual file manager
143 .SH "SYNOPSIS"
144 .IX Header "SYNOPSIS"
145 \&\fBranger\fR [\fB\-\-version\fR] [\fB\-\-help\fR] [\fB\-\-debug\fR] [\fB\-\-clean\fR]
146 [\fB\-\-cachedir\fR=\fIdirectory\fR] [\fB\-\-confdir\fR=\fIdirectory\fR]
147 [\fB\-\-datadir\fR=\fIdirectory\fR] [\fB\-\-copy\-config\fR=\fIwhich\fR]
148 [\fB\-\-choosefile\fR=\fItarget\fR] [\fB\-\-choosefiles\fR=\fItarget\fR]
149 [\fB\-\-choosedir\fR=\fItarget\fR] [\fB\-\-selectfile\fR=\fIfilepath\fR]
150 [\fB\-\-show\-only\-dirs\fR]
151 [\fB\-\-list\-unused\-keys\fR] [\fB\-\-list\-tagged\-files\fR=\fItag\fR]
152 [\fB\-\-profile\fR] [\fB\-\-cmd\fR=\fIcommand\fR] [\fIpath ...\fR]
153 .SH "DESCRIPTION"
154 .IX Header "DESCRIPTION"
155 ranger is a console file manager with \s-1VI\s0 key bindings.
156 .SH "RESOURCES"
157 .IX Header "RESOURCES"
158 \&\fIThis manual\fR contains instructions on how to use and configure ranger.
160 \&\fIInside ranger\fR, you can press \fI?\fR for a list of key bindings, commands or
161 settings.
163 The \fI\s-1README\s0\fR contains install instructions.
165 The file \fI\s-1HACKING\s0.md\fR contains guidelines for code modification.
167 The directory \fIdoc/configs\fR contains configuration files.  They are usually
168 installed to \fI/usr/share/doc/ranger/config\fR and can be obtained with ranger's
169 \&\-\-copy\-config option.
171 The directory \fIexamples\fR contains reference implementations for ranger
172 plugins, sample configuration files and some programs for integrating ranger
173 with other software.  They are usually installed to
174 \&\fI/usr/share/doc/ranger/examples\fR.
176 The man page of \fBrifle\fR\|(1) describes the functions of the file opener
178 The section \fI\s-1LINKS\s0\fR of this man page contains further resources.
179 .SH "POSITIONAL ARGUMENTS"
180 .IX Header "POSITIONAL ARGUMENTS"
181 .IP "\fIpath ...\fR" 14
182 .IX Item "path ..."
183 Each path will be opened in a tab and if the path is a file it will be selected.
184 Omitting this is equivalent to providing the current directory.
185 .SH "OPTIONS"
186 .IX Header "OPTIONS"
187 .IP "\fB\-d\fR, \fB\-\-debug\fR" 14
188 .IX Item "-d, --debug"
189 Activate the debug mode: Whenever an error occurs, ranger will exit and print a
190 full traceback.  The default behavior is to merely print the name of the
191 exception in the statusbar/log and try to keep running.
192 .IP "\fB\-c\fR, \fB\-\-clean\fR" 14
193 .IX Item "-c, --clean"
194 Activate the clean mode:  ranger will not access or create any configuration
195 files nor will it leave any traces on your system.  This is useful when your
196 configuration is broken, when you want to avoid clutter, etc.
197 .IP "\fB\-\-cachedir\fR=\fIdir\fR" 14
198 .IX Item "--cachedir=dir"
199 Change the cache directory of ranger from \f(CW$XDG_CACHE_HOME\fR or ~/.cache/ranger to \*(L"dir\*(R".
200 .IP "\fB\-r\fR \fIdir\fR, \fB\-\-confdir\fR=\fIdir\fR" 14
201 .IX Item "-r dir, --confdir=dir"
202 Change the configuration directory of ranger from \f(CW$XDG_CONFIG_HOME\fR or ~/.config/ranger to \*(L"dir\*(R".
203 .IP "\fB\-\-datadir\fR=\fIdir\fR" 14
204 .IX Item "--datadir=dir"
205 Change the data directory of ranger from \f(CW$XDG_DATA_HOME\fR or ~/.local/share/ranger to \*(L"dir\*(R".
206 .IP "\fB\-\-copy\-config\fR=\fIfile\fR" 14
207 .IX Item "--copy-config=file"
208 Create copies of the default configuration files in your local configuration
209 directory.  Existing ones will not be overwritten.  Possible values: \fIall\fR,
210 \&\fIcommands\fR, \fIcommands_full\fR, \fIrc\fR, \fIrifle\fR, \fIscope\fR.
212 Note: You may want to disable loading of the global configuration files by
213 exporting \fIRANGER_LOAD_DEFAULT_RC=FALSE\fR in your environment.  See also:
214 \&\fB\s-1FILES\s0\fR, \fB\s-1ENVIRONMENT\s0\fR
216 \&\-\-copy\-config=\fBcommands\fR will copy only a small sample configuration file with
217 a thoroughly commented example.  It is recommended to keep this file tidy to
218 avoid getting defunct commands on ranger upgrades.  The full default
219 commands.py can be copied with \-\-copy\-config=\fBcommands_full\fR, but that file
220 will be ignored by ranger and serves only as a reference for making your own
221 commands.
222 .IP "\fB\-\-choosefile\fR=\fItargetfile\fR" 14
223 .IX Item "--choosefile=targetfile"
224 Allows you to pick a file with ranger.  This changes the behavior so that when
225 you open a file, ranger will exit and write the absolute path of that file into
226 \&\fItargetfile\fR.
227 .IP "\fB\-\-choosefiles\fR=\fItargetfile\fR" 14
228 .IX Item "--choosefiles=targetfile"
229 Allows you to pick multiple files with ranger.  This changes the behavior so
230 that when you open a file, ranger will exit and write the absolute paths of all
231 selected files into \fItargetfile\fR, adding one newline after each filename.
232 .IP "\fB\-\-choosedir\fR=\fItargetfile\fR" 14
233 .IX Item "--choosedir=targetfile"
234 Allows you to pick a directory with ranger.  When you exit ranger, it will
235 write the last visited directory into \fItargetfile\fR.
236 .IP "\fB\-\-selectfile\fR=\fItargetfile\fR" 14
237 .IX Item "--selectfile=targetfile"
238 Open ranger with \fItargetfile\fR selected. This is a legacy option, superseded by
239 the behavior for the \s-1POSITIONAL ARGUMENTS.\s0
240 .IP "\fB\-\-show\-only\-dirs\fR" 14
241 .IX Item "--show-only-dirs"
242 Display only the directories. May be used in conjunction with
243 \&\fB\-\-choosedir\fR=\fItargetfile\fR.
244 .IP "\fB\-\-list\-unused\-keys\fR" 14
245 .IX Item "--list-unused-keys"
246 List common keys which are not bound to any action in the \*(L"browser\*(R" context.
247 This list is not complete, you can bind any key that is supported by curses:
248 use the key code returned by \f(CW\*(C`getch()\*(C'\fR.
249 .IP "\fB\-\-list\-tagged\-files\fR=\fItag\fR" 14
250 .IX Item "--list-tagged-files=tag"
251 List all files which are tagged with the given tag.  Note: Tags are single
252 characters.  The default tag is \*(L"*\*(R"
253 .IP "\fB\-\-profile\fR" 14
254 .IX Item "--profile"
255 Print statistics of \s-1CPU\s0 usage on exit.
256 .IP "\fB\-\-cmd\fR=\fIcommand\fR" 14
257 .IX Item "--cmd=command"
258 Execute the command after the configuration has been read.  Use this option
259 multiple times to run multiple commands.
260 .IP "\fB\-\-version\fR" 14
261 .IX Item "--version"
262 Print the version and exit.
263 .IP "\fB\-h\fR, \fB\-\-help\fR" 14
264 .IX Item "-h, --help"
265 Print a list of options and exit.
266 .SH "CONCEPTS"
267 .IX Header "CONCEPTS"
268 This part explains how certain parts of ranger work and how they can be used
269 efficiently.
270 .SS "\s-1TAGS\s0"
271 .IX Subsection "TAGS"
272 Tags are single characters which are displayed left of a filename.  You can use
273 tags however you want.  Press \*(L"t\*(R" to toggle tags and \*(L"ut\*(R" to remove any tags of
274 the selection. The default tag is an Asterisk (\*(L"*\*(R"), but you can use any tag by
275 typing \fI"<tagname>\fR.
276 .SS "\s-1PREVIEWS\s0"
277 .IX Subsection "PREVIEWS"
278 By default, only text files are previewed, but you can enable external preview
279 scripts by setting the option \f(CW\*(C`use_preview_script\*(C'\fR and \f(CW\*(C`preview_files\*(C'\fR to true.
281 This default script is \fI\f(CI%rangerdir\fI/data/scope.sh\fR. It contains more
282 documentation and calls to the programs \fIlynx\fR and \fIelinks\fR for html,
283 \&\fIhighlight\fR for text/code, \fIimg2txt\fR for images, \fIatool\fR for archives,
284 \&\fIpdftotext\fR or \fImutool\fR for PDFs and \fImediainfo\fR for video and audio files.
286 Install these programs (just the ones you need) and scope.sh will automatically
287 use them.
289 Independently of the preview script, there is a feature to preview images
290 by drawing them directly into the terminal. To enable this feature, set the
291 option \f(CW\*(C`preview_images\*(C'\fR to true and enable one of the image preview modes:
293 \fIw3m\fR
294 .IX Subsection "w3m"
296 This does not work over ssh, requires certain terminals (tested on \*(L"xterm\*(R" and
297 \&\*(L"urxvt\*(R") and is incompatible with tmux, although it works with screen.
299 To enable this feature, install the program \*(L"w3m\*(R" and set the option
300 \&\f(CW\*(C`preview_images_method\*(C'\fR to w3m.
302 \fIiTerm2\fR
303 .IX Subsection "iTerm2"
305 This only works in iTerm2 compiled with image preview support, but works over
306 ssh.
308 To enable this feature, set the option \f(CW\*(C`preview_images_method\*(C'\fR to iterm2.
310 This feature relies on the dimensions of the terminal's font.  By default, a
311 width of 8 and height of 11 are used.  To use other values, set the options
312 \&\f(CW\*(C`iterm2_font_width\*(C'\fR and \f(CW\*(C`iterm2_font_height\*(C'\fR to the desired values.
314 \fIterminology\fR
315 .IX Subsection "terminology"
317 This only works in terminology. It can render vector graphics, but works only locally.
319 To enable this feature, set the option \f(CW\*(C`preview_images_method\*(C'\fR to terminology.
321 \fIurxvt\fR
322 .IX Subsection "urxvt"
324 This only works in urxvt compiled with pixbuf support. Does not work over ssh.
326 Essentially this mode sets an image as a terminal background temporarily, so it
327 will break any previously set image background.
329 To enable this feature, set the option \f(CW\*(C`preview_images_method\*(C'\fR to urxvt.
331 \fIurxvt-full\fR
332 .IX Subsection "urxvt-full"
334 The same as urxvt but utilizing not only the preview pane but the whole terminal
335 window.
337 To enable this feature, set the option \f(CW\*(C`preview_images_method\*(C'\fR to urxvt-full.
339 \fIkitty\fR
340 .IX Subsection "kitty"
342 This only works on Kitty. It requires \s-1PIL\s0 (or pillow) to work.
343 Allows remote image previews, for example in an ssh session.
345 To enable this feature, set the option \f(CW\*(C`preview_images_method\*(C'\fR to kitty.
346 .SS "\s-1SELECTION\s0"
347 .IX Subsection "SELECTION"
348 The \fIselection\fR is defined as \*(L"All marked files \s-1IF THERE ARE ANY,\s0 otherwise
349 the current file.\*(R"  Be aware of this when using the :delete command, which
350 deletes all files in the selection.
352 You can mark files by pressing <Space>, v, etc.  A yellow \fBMrk\fR symbol at the
353 bottom right indicates that there are marked files in this directory.
354 .SS "\s-1MACROS\s0"
355 .IX Subsection "MACROS"
356 Macros can be used in commands to abbreviate things.
358 .Vb 6
359 \& %f   the highlighted file
360 \& %d   the path of the current directory
361 \& %s   the selected files in the current directory
362 \& %t   all tagged files in the current directory
363 \& %c   the full paths of the currently copied/cut files
364 \& %p   the full paths of selected files
367 The macros \f(CW%f\fR, \f(CW%d\fR, \f(CW%p\fR, and \f(CW%s\fR also have upper case variants, \f(CW%F\fR, \f(CW%D\fR, \f(CW%P\fR, and
368 \&\f(CW%S\fR, which refer to the next tab.  To refer to specific tabs, add a number in
369 between.  (%7s = selection of the seventh tab.)
371 \&\f(CW%c\fR is the only macro which ranges out of the current directory. So you may
372 \&\*(L"abuse\*(R" the copying function for other purposes, like diffing two files which
373 are in different directories:
375 .Vb 2
376 \& Yank the file A (type yy), move to the file B, then type
377 \& @diff %c %f
380 Macros for file paths are generally shell-escaped so they can be used in the
381 \&\f(CW\*(C`shell\*(C'\fR command.
383 Additionally, if you create a key binding that uses <any>, a special statement
384 which accepts any key, then the macro \f(CW%any\fR (or \f(CW%any0\fR, \f(CW%any1\fR, \f(CW%any2\fR, ...) can be
385 used in the command to get the key that was pressed.
387 The macro \f(CW%rangerdir\fR expands to the directory of ranger's python library, you
388 can use it for something like this command:
389   alias show_commands shell less \f(CW%rangerdir\fR/config/commands.py
391 \&\f(CW%confdir\fR expands to the directory given by \fB\-\-confdir\fR.
393 \&\f(CW%datadir\fR expands to the directory given by \fB\-\-datadir\fR.
395 The macro \f(CW%space\fR expands to a space character. You can use it to add spaces to
396 the end of a command when needed, while preventing editors to strip spaces off
397 the end of the line automatically.
399 To write a literal %, you need to escape it by writing %%.
400 .SS "\s-1BOOKMARKS\s0"
401 .IX Subsection "BOOKMARKS"
402 Type \fBm<key>\fR to bookmark the current directory. You can re-enter this
403 directory by typing \fB`<key>\fR. <key> can be any letter or digit.  Unlike vim,
404 both lowercase and uppercase bookmarks are persistent.
406 Each time you jump to a bookmark, the special bookmark at key ` will be set
407 to the last directory. So typing \*(L"``\*(R" gets you back to where you were before.
409 Bookmarks are selectable when tabbing in the :cd command.
411 Note: The bookmarks ' (Apostrophe) and ` (Backtick) are the same.
412 .SS "\s-1RIFLE\s0"
413 .IX Subsection "RIFLE"
414 Rifle is the file opener of ranger.  It can be used as a standalone program or
415 a python module.  It is located at \fIranger/ext/rifle.py\fR.  In contrast to
416 other, more simple file openers, rifle can automatically find installed
417 programs so it can be used effectively out of the box on a variety of systems.
419 It's configured in \fIrifle.conf\fR through a list of conditions and commands.
420 For each line the conditions are checked and if they are met, the respective
421 command is taken into consideration.  By default, simply the first matching
422 rule is used.  In ranger, you can list and choose rules by typing \*(L"r\*(R" or simply
423 by typing \*(L"<rulenumber><enter>\*(R".  If you use rifle standalone, you can list all
424 rules with the \*(L"\-l\*(R" option and pick a rule with \*(L"\-p <number>\*(R".
426 The rules, along with further documentation, are contained in
427 \&\fIranger/config/rifle.conf\fR.
428 .SS "\s-1FLAGS\s0"
429 .IX Subsection "FLAGS"
430 Flags give you a way to modify the behavior of the spawned process.  They are
431 used in the commands \f(CW\*(C`:open_with\*(C'\fR (key \*(L"r\*(R") and \f(CW\*(C`:shell\*(C'\fR (key \*(L"!\*(R").
433 .Vb 4
434 \& f   Fork the process.  (Run in background)
435 \& c   Run the current file only, instead of the selection
436 \& r   Run application with root privilege (requires sudo)
437 \& t   Run application in a new terminal window
440 There are some additional flags that can currently be used only in the \f(CW\*(C`shell\*(C'\fR
441 command: (for example \f(CW\*(C`:shell \-w df\*(C'\fR)
443 .Vb 3
444 \& p   Redirect output to the pager
445 \& s   Silent mode.  Output will be discarded.
446 \& w   Wait for an Enter\-press when the process is done
449 By default, all the flags are off unless specified otherwise in the
450 \&\fIrifle.conf\fR configuration file.  You can specify as many flags as you want.
451 An uppercase flag negates the effect: \*(L"ffcccFsf\*(R" is equivalent to \*(L"cs\*(R".
453 The terminal program name for the \*(L"t\*(R" flag is taken from the environment
454 variable \f(CW$TERMCMD\fR.  If it doesn't exist, it tries to extract it from \f(CW$TERM\fR,
455 uses \*(L"x\-terminal-emulator\*(R" as a fallback, and then \*(L"xterm\*(R" if that fails.
457 Examples: \f(CW\*(C`:open_with c\*(C'\fR will open the file that you currently point at, even
458 if you have selected other files.  \f(CW\*(C`:shell \-w df\*(C'\fR will run \*(L"df\*(R" and wait for
459 you to press Enter before switching back to ranger.
460 .SS "\s-1PLUGINS\s0"
461 .IX Subsection "PLUGINS"
462 ranger's plugin system consists of python files which are located in
463 \&\fI~/.config/ranger/plugins/\fR and are imported in alphabetical order when
464 starting ranger.  A plugin changes rangers behavior by overwriting or extending
465 a function that ranger uses.  This allows you to change pretty much every part
466 of ranger, but there is no guarantee that things will continue to work in
467 future versions as the source code evolves.
469 Adding new commands via a plugin as simple as specifying them like you would do
470 in the \fIcommands.py\fR.
472 There are some hooks that are specifically made for the use in plugins.  They
473 are functions that start with hook_ and can be found throughout the code.
475 .Vb 1
476 \& grep \*(Aqdef hook_\*(Aq \-r /path/to/rangers/source
479 Also try:
481 .Vb 1
482 \& pydoc ranger.api
485 Note that you should \s-1NOT\s0 simply overwrite a function unless you know what
486 you're doing.  Instead, save the existing function and call it from your new
487 one.  This way, multiple plugins can use the same hook.  There are several
488 sample plugins in the \fI/usr/share/doc/ranger/examples/\fR directory, including a
489 hello-world plugin that describes this procedure.
490 .SH "KEY BINDINGS"
491 .IX Header "KEY BINDINGS"
492 Key bindings are defined in the file \fI\f(CI%rangerdir\fI/config/rc.conf\fR.  Check this
493 file for a list of all key bindings.  You can copy it to your local
494 configuration directory with the \-\-copy\-config=rc option.
496 Many key bindings take an additional numeric argument.  Type \fI5j\fR to move
497 down 5 lines, \fI2l\fR to open a file in mode 2, \fI10<Space>\fR to mark 10 files.
499 This list contains the most useful bindings:
500 .SS "\s-1MAIN BINDINGS\s0"
501 .IX Subsection "MAIN BINDINGS"
502 .IP "h, j, k, l" 14
503 .IX Item "h, j, k, l"
504 Move left, down, up or right
505 .IP "^D or J, ^U or K" 14
506 .IX Item "^D or J, ^U or K"
507 Move a half page down, up
508 .IP "H, L" 14
509 .IX Item "H, L"
510 Move back and forward in the history
511 .IP "gg" 14
512 .IX Item "gg"
513 Move to the top
514 .IP "G" 14
515 .IX Item "G"
516 Move to the bottom
517 .IP "[, ]" 14
518 Move up and down in the parent directory.
519 .IP "^R" 14
520 .IX Item "^R"
521 Reload everything
522 .IP "F" 14
523 .IX Item "F"
524 Toggle \fIfreeze_files\fR setting.  When active (indicated by a cyan \fI\s-1FROZEN\s0\fR
525 message in the status bar), directories and files will not be loaded, improving
526 performance when all the files you need are already loaded.  This does not
527 affect file previews, which can be toggled with \fIzI\fR.  Also try disabling the
528 preview of directories with \fIzP\fR.
529 .IP "^L" 14
530 .IX Item "^L"
531 Redraw the screen
532 .IP "i" 14
533 .IX Item "i"
534 Inspect the current file in a bigger window.
535 .IP "E" 14
536 .IX Item "E"
537 Edit the current file in \f(CW$VISUAL\fR otherwise \f(CW$EDITOR\fR otherwise \*(L"vim\*(R"
538 .IP "S" 14
539 .IX Item "S"
540 Open a shell in the current directory
541 .IP "?" 14
542 Opens this man page
543 .IP "W" 14
544 .IX Item "W"
545 Opens the log window where you can review messages that pop up at the bottom.
546 .IP "w" 14
547 .IX Item "w"
548 Opens the task window where you can view and modify background processes that
549 currently run in ranger.  In there, you can type \*(L"dd\*(R" to abort a process and
550 \&\*(L"J\*(R" or \*(L"K\*(R" to change the priority of a process.  Only one process is run at a
551 time.
552 .IP "^C" 14
553 .IX Item "^C"
554 Stop the currently running background process that ranger has started, like
555 copying files, loading directories or file previews.
556 .IP "<octal>=, +<who><what>, \-<who><what>" 14
557 .IX Item "<octal>=, +<who><what>, -<who><what>"
558 Change the permissions of the selection.  For example, \f(CW\*(C`777=\*(C'\fR is equivalent to
559 \&\f(CW\*(C`chmod 777 %s\*(C'\fR, \f(CW\*(C`+ar\*(C'\fR does \f(CW\*(C`chmod a+r %s\*(C'\fR, \f(CW\*(C`\-ow\*(C'\fR does \f(CW\*(C`chmod o\-w %s\*(C'\fR etc.
560 .IP "yy" 14
561 .IX Item "yy"
562 Copy (yank) the selection, like pressing Ctrl+C in modern \s-1GUI\s0 programs.  (You
563 can also type \*(L"ya\*(R" to add files to the copy buffer, \*(L"yr\*(R" to remove files again,
564 or \*(L"yt\*(R" for toggling.)
565 .IP "dd" 14
566 .IX Item "dd"
567 Cut the selection, like pressing Ctrl+X in modern \s-1GUI\s0 programs.  (There are
568 also \*(L"da\*(R", \*(L"dr\*(R" and \*(L"dt\*(R" shortcuts equivalent to \*(L"ya\*(R", \*(L"yr\*(R" and \*(L"yt\*(R".)
569 .IP "pp" 14
570 .IX Item "pp"
571 Paste the files which were previously copied or cut, like pressing Ctrl+V in
572 modern \s-1GUI\s0 programs.
573 .IP "po" 14
574 .IX Item "po"
575 Paste the copied/cut files, overwriting existing files.
576 .IP "pP, pO" 14
577 .IX Item "pP, pO"
578 Like pp and po, but queues the operation so that it will be executed \fIafter\fR
579 any other operations.  Reminder: type \f(CW\*(C`w\*(C'\fR to open the task window.
580 .IP "pl, pL" 14
581 .IX Item "pl, pL"
582 Create symlinks (absolute or relative) to the copied files
583 .IP "phl" 14
584 .IX Item "phl"
585 Create hardlinks to the copied files
586 .IP "pht" 14
587 .IX Item "pht"
588 Duplicate the subdirectory tree of the copied directory, then create
589 hardlinks for each contained file into the new directory tree.
590 .IP "m\fIX\fR" 14
591 .IX Item "mX"
592 Create a bookmark with the name \fIX\fR
593 .IP "`\fIX\fR" 14
594 .IX Item "`X"
595 Move to the bookmark with the name \fIX\fR
596 .IP "n" 14
597 .IX Item "n"
598 Find the next file.  By default, this gets you to the newest file in the
599 directory, but if you search something using the keys /, cm, ct, ..., it will
600 get you to the next found entry.
601 .IP "N" 14
602 .IX Item "N"
603 Find the previous file.
604 .IP "o\fIX\fR" 14
605 .IX Item "oX"
606 Change the sort method (like in mutt)
607 .IP "z\fIX\fR" 14
608 .IX Item "zX"
609 Change settings.  See the settings section for a list of settings and their
610 hotkey.
611 .IP "u\fI?\fR" 14
612 .IX Item "u?"
613 Universal undo-key.  Depending on the key that you press after \*(L"u\*(R", it either
614 restores closed tabs (uq), removes tags (ut), clears the copy/cut buffer (ud),
615 starts the reversed visual mode (uV) or clears the selection (uv).
616 .IP "f" 14
617 .IX Item "f"
618 Quickly navigate by entering a part of the filename.
619 .IP "Space" 14
620 .IX Item "Space"
621 Mark a file.
622 .IP "v" 14
623 .IX Item "v"
624 Toggle the mark-status of all files
625 .IP "V" 14
626 .IX Item "V"
627 Starts the visual mode, which selects all files between the starting point and
628 the cursor until you press \s-1ESC.\s0  To unselect files in the same way, use \*(L"uV\*(R".
629 .IP "/" 14
630 Search for files in the current directory.
631 .IP ":" 14
632 Open the console.
633 .IP "!" 14
634 Open the console with the content \*(L"shell \*(R" so you can quickly run commands
635 .IP "@" 14
636 Open the console with the content \*(L"shell  \f(CW%s\fR\*(R", placing the cursor before the
637 \&\*(L" \f(CW%s\fR\*(R" so you can quickly run commands with the current selection as the
638 argument.
639 .IP "r" 14
640 .IX Item "r"
641 Open the console with the content \*(L"open with \*(R" so you can decide which program
642 to use to open the current file selection.
643 .IP "cd" 14
644 .IX Item "cd"
645 Open the console with the content \*(L"cd \*(R"
646 .IP "^P" 14
647 .IX Item "^P"
648 Open the console with the most recent command.
649 .IP "Alt\-\fIN\fR" 14
650 .IX Item "Alt-N"
651 Open a tab. N has to be a number from 0 to 9. If the tab doesn't exist yet, it
652 will be created.
653 .IP "gn, ^N" 14
654 .IX Item "gn, ^N"
655 Create a new tab.
656 .IP "gt, gT" 14
657 .IX Item "gt, gT"
658 Go to the next or previous tab. You can also use \s-1TAB\s0 and \s-1SHIFT+TAB\s0 instead.
659 .IP "gc, ^W" 14
660 .IX Item "gc, ^W"
661 Close the current tab.  The last tab cannot be closed this way.
662 .IP "M" 14
663 .IX Item "M"
664 A key chain that allows you to quickly change the line mode of all the files of
665 the current directory.  For a more permanent solution, use the command
666 \&\*(L"default_linemode\*(R" in your rc.conf.
667 .IP ".n" 14
668 .IX Item ".n"
669 Apply a new filename filter.
670 .IP ".m" 14
671 .IX Item ".m"
672 Apply a new mimetype filter.
673 .IP ".d" 14
674 .IX Item ".d"
675 Apply the typefilter \*(L"directory\*(R".
676 .IP ".f" 14
677 .IX Item ".f"
678 Apply the typefilter \*(L"file\*(R".
679 .IP ".l" 14
680 .IX Item ".l"
681 Apply the typefilter \*(L"symlink\*(R".
682 .IP ".|" 14
683 Combine the two topmost filters from the filter stack in the \*(L"\s-1OR\*(R"\s0
684 relationship, instead of the \*(L"\s-1AND\*(R"\s0 used implicitly.
685 .IP ".&" 14
686 Explicitly combine the two topmost filters in the \*(L"\s-1AND\*(R"\s0
687 relationship. Usually not needed though might be useful in more
688 complicated scenarios.
689 .IP ".!" 14
690 Negate the topmost filter.
691 .IP ".r" 14
692 .IX Item ".r"
693 Rotate the filter stack by N elements. Just confirm with enter to
694 rotate by 1, i.e. move the topmost element to the bottom of the stack.
695 .IP ".c" 14
696 .IX Item ".c"
697 Clear the filter stack.
698 .IP ".*" 14
699 Decompose the topmost filter combinator (e.g. \f(CW\*(C`.!\*(C'\fR, \f(CW\*(C`.|\*(C'\fR).
700 .IP ".p" 14
701 .IX Item ".p"
702 Pop the topmost filter from the filter stack.
703 .IP ".." 14
704 Show the current filter stack state.
705 .SS "READLINE-LIKE \s-1BINDINGS IN THE CONSOLE\s0"
706 .IX Subsection "READLINE-LIKE BINDINGS IN THE CONSOLE"
707 .IP "^B, ^F" 14
708 .IX Item "^B, ^F"
709 Move left and right (B for back, F for forward)
710 .IP "^P, ^N" 14
711 .IX Item "^P, ^N"
712 Move up and down (P for previous, N for Next)
713 .IP "^A, ^E" 14
714 .IX Item "^A, ^E"
715 Move to the start or to the end
716 .IP "Alt-B, Alt-LEFT" 14
717 .IX Item "Alt-B, Alt-LEFT"
718 Move backwards by words.
719 .IP "Alt-F, Alt-RIGHT" 14
720 .IX Item "Alt-F, Alt-RIGHT"
721 Move forwards by words.
722 .IP "^D" 14
723 .IX Item "^D"
724 Delete the current character.
725 .IP "^H" 14
726 .IX Item "^H"
727 Backspace.
728 .SH "MOUSE BUTTONS"
729 .IX Header "MOUSE BUTTONS"
730 .IP "Left Mouse Button" 4
731 .IX Item "Left Mouse Button"
732 Click on something and you'll move there.  To run a file, \*(L"enter\*(R" it, like a
733 directory, by clicking on the preview.
734 .IP "Right Mouse Button" 4
735 .IX Item "Right Mouse Button"
736 Enter a directory or run a file.
737 .IP "Scroll Wheel" 4
738 .IX Item "Scroll Wheel"
739 Scrolls up or down.  You can point at the column of the parent directory while
740 scrolling to switch directories.
741 .SH "SETTINGS"
742 .IX Header "SETTINGS"
743 This section lists all built-in settings of ranger.  The valid types for the
744 value are in [brackets].  The hotkey to toggle the setting is in <brakets>, if
745 a hotkey exists.
747 Settings can be changed in the file \fI~/.config/ranger/rc.conf\fR or on the
748 fly with the command \fB:set option value\fR.  Examples:
750 .Vb 2
751 \& set column_ratios 1,2,3
752 \& set show_hidden true
755 Toggling options can be done with:
757 .Vb 1
758 \& set show_hidden!
761 The different types of settings and an example for each type:
763 .Vb 7
764 \& setting type   | example values
765 \& \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-
766 \& bool           | true, false
767 \& integer        | 1, 23, 1337
768 \& string         | foo, hello world
769 \& list           | 1,2,3,4
770 \& none           | none
773 You can view a list of all settings and their current values by pressing \*(L"3?\*(R"
774 in ranger.
775 .IP "automatically_count_files [bool]" 4
776 .IX Item "automatically_count_files [bool]"
777 Should ranger count and display the number of files in each directory
778 as soon as it's visible?  This gets slow with remote file systems.  Turning it
779 off will still allow you to see the number of files after entering the
780 directory.
781 .IP "autosave_bookmarks [bool]" 4
782 .IX Item "autosave_bookmarks [bool]"
783 Save bookmarks (used with mX and `X) instantly?  This helps to synchronize
784 bookmarks between multiple ranger instances but leads to *slight* performance
785 loss.  When false, bookmarks are saved when ranger is exited.
786 .IP "autoupdate_cumulative_size [bool]" 4
787 .IX Item "autoupdate_cumulative_size [bool]"
788 You can display the \*(L"real\*(R" cumulative size of directories by using the command
789 :get_cumulative_size or typing \*(L"dc\*(R".  The size is expensive to calculate and
790 will not be updated automatically.  You can choose to update it automatically
791 though by turning on this option.
792 .IP "cd_bookmarks [bool]" 4
793 .IX Item "cd_bookmarks [bool]"
794 Specify whether bookmarks should be included in the tab completion of the \*(L"cd\*(R"
795 command.
796 .IP "cd_tab_case [string]" 4
797 .IX Item "cd_tab_case [string]"
798 Changes case sensitivity for the \*(L"cd\*(R" command tab completion. Possible values are:
800 .Vb 3
801 \& sensitive
802 \& insensitive
803 \& smart
805 .IP "cd_tab_fuzzy [bool]" 4
806 .IX Item "cd_tab_fuzzy [bool]"
807 Use fuzzy tab completion with the \*(L"cd\*(R" command. For example,
808 \&\fB:cd /u/lo/b<\s-1TAB\s0>\fR expands to \fB:cd /usr/local/bin\fR.
809 .IP "clear_filters_on_dir_change [bool]" 4
810 .IX Item "clear_filters_on_dir_change [bool]"
811 If set to 'true', persistent filters would be cleared upon leaving the directory
812 .IP "collapse_preview [bool] <zc>" 4
813 .IX Item "collapse_preview [bool] <zc>"
814 When no preview is visible, should the last column be squeezed to make use of
815 the whitespace?
816 .IP "colorscheme [string]" 4
817 .IX Item "colorscheme [string]"
818 Which colorscheme to use?  These colorschemes are available by default:
819 \&\fBdefault\fR, \fBjungle\fR, \fBsnow\fR.  Snow is a monochrome scheme, jungle replaces
820 blue directories with green ones for better visibility on certain terminals.
821 .IP "column_ratios [list]" 4
822 .IX Item "column_ratios [list]"
823 How many columns are there, and what are their relative widths?  For example, a
824 value of 1,1,1 would mean 3 evenly sized columns. 1,1,1,1,4 means 5 columns
825 with the preview column being as large as the other columns combined.
826 .IP "confirm_on_delete [string]" 4
827 .IX Item "confirm_on_delete [string]"
828 Ask for a confirmation when running the \*(L"delete\*(R" command?  Valid values are
829 \&\*(L"always\*(R" (default), \*(L"never\*(R", \*(L"multiple\*(R". With \*(L"multiple\*(R", ranger will ask only
830 if you delete multiple files at once.
831 .IP "dirname_in_tabs [bool]" 4
832 .IX Item "dirname_in_tabs [bool]"
833 Display the directory name in tabs?
834 .IP "display_size_in_main_column [bool]" 4
835 .IX Item "display_size_in_main_column [bool]"
836 Display the file size in the main column?
837 .IP "display_size_in_status_bar [bool]" 4
838 .IX Item "display_size_in_status_bar [bool]"
839 Display the file size in the status bar?
840 .IP "display_free_space_in_status_bar [bool]" 4
841 .IX Item "display_free_space_in_status_bar [bool]"
842 Display the free disk space in the status bar?
843 .IP "display_tags_in_all_columns [bool]" 4
844 .IX Item "display_tags_in_all_columns [bool]"
845 Display tags in all columns?
846 .IP "draw_borders [string]" 4
847 .IX Item "draw_borders [string]"
848 Draw borders around or between the columns? Possible values are:
850 .Vb 4
851 \& none           no borders of any sort
852 \& outline        draw an outline around all the columns
853 \& separators     draw only vertical lines between columns
854 \& both           both of the above
856 .IP "draw_progress_bar_in_status_bar [bool]" 4
857 .IX Item "draw_progress_bar_in_status_bar [bool]"
858 Draw a progress bar in the status bar which displays the average state of all
859 currently running tasks which support progress bars?
860 .IP "flushinput [bool] <zi>" 4
861 .IX Item "flushinput [bool] <zi>"
862 Flush the input after each key hit?  One advantage is that when scrolling down
863 with \*(L"j\*(R", ranger stops scrolling instantly when you release the key.  One
864 disadvantage is that when you type commands blindly, some keys might get lost.
865 .IP "freeze_files [bool] <F>" 4
866 .IX Item "freeze_files [bool] <F>"
867 When active, directories and files will not be loaded, improving performance
868 when all the files you need are already loaded.  This does not affect file
869 previews.
870 .IP "global_inode_type_filter [string]" 4
871 .IX Item "global_inode_type_filter [string]"
872 Like filter_inode_type, but globally for all directories.  Useful in
873 combination with \fB\-\-choosedir\fR:
875 .Vb 1
876 \& ranger \-\-choosedir=/tmp/x \-\-cmd=\*(Aqset global_inode_type_filter d\*(Aq
878 .IP "hidden_filter [string]" 4
879 .IX Item "hidden_filter [string]"
880 A regular expression pattern for files which should be hidden.  For example,
881 this pattern will hide all files that start with a dot or end with a tilde.
883 .Vb 1
884 \& set hidden_filter ^\e.|~$
886 .IP "hint_collapse_threshold [int]" 4
887 .IX Item "hint_collapse_threshold [int]"
888 The key hint lists up to this size have their sublists expanded.
889 Otherwise the submaps are replaced with \*(L"...\*(R".
890 .IP "hostname_in_titlebar [bool]" 4
891 .IX Item "hostname_in_titlebar [bool]"
892 Show hostname in titlebar?
893 .IP "idle_delay [integer]" 4
894 .IX Item "idle_delay [integer]"
895 The delay that ranger idly waits for user input, in milliseconds, with a
896 resolution of 100ms.  Lower delay reduces lag between directory updates but
897 increases \s-1CPU\s0 load.
898 .IP "iterm2_font_height [integer]" 4
899 .IX Item "iterm2_font_height [integer]"
900 Change the assumed font height in iTerm2, which may help with iTerm image
901 previews
902 .IP "iterm2_font_width [integer]" 4
903 .IX Item "iterm2_font_width [integer]"
904 Change the assumed font width in iTerm2, which may help with iTerm image
905 previews
906 .IP "line_numbers [string]" 4
907 .IX Item "line_numbers [string]"
908 Show line numbers in main column.  Possible values are:
910 .Vb 3
911 \& false      turn the feature off
912 \& absolute   absolute line numbers for use with "<N>gg"
913 \& relative   relative line numbers for "<N>k" or "<N>j"
915 .IP "max_console_history_size [integer, none]" 4
916 .IX Item "max_console_history_size [integer, none]"
917 How many console commands should be kept in history?  \*(L"none\*(R" will disable the
918 limit.
919 .IP "max_history_size [integer, none]" 4
920 .IX Item "max_history_size [integer, none]"
921 How many directory changes should be kept in history?
922 .IP "metadata_deep_search [bool]" 4
923 .IX Item "metadata_deep_search [bool]"
924 When the metadata manager module looks for metadata, should it only look for a
925 \&\*(L".metadata.json\*(R" file in the current directory, or do a deep search and check
926 all directories above the current one as well?
927 .IP "mouse_enabled [bool] <zm>" 4
928 .IX Item "mouse_enabled [bool] <zm>"
929 Enable mouse input?
930 .IP "one_indexed [bool]" 4
931 .IX Item "one_indexed [bool]"
932 Start line numbers from 1.  Possible values are:
934 .Vb 2
935 \& false      start line numbers from 0
936 \& true       start line numbers from 1
938 .IP "open_all_images [bool]" 4
939 .IX Item "open_all_images [bool]"
940 Open all images in this directory when running certain image viewers like feh
941 or sxiv?  You can still open selected files by marking them.
942 .IP "padding_right [bool]" 4
943 .IX Item "padding_right [bool]"
944 When collapse_preview is on and there is no preview, should there remain a
945 little padding on the right?  This allows you to click into that space to run
946 the file.
947 .IP "preview_directories [bool] <zP>" 4
948 .IX Item "preview_directories [bool] <zP>"
949 Preview directories in the preview column?
950 .IP "preview_files [bool] <zp>" 4
951 .IX Item "preview_files [bool] <zp>"
952 Preview files in the preview column?
953 .IP "preview_images [bool]" 4
954 .IX Item "preview_images [bool]"
955 Draw images inside the console with the external program w3mimgpreview?
956 .IP "preview_images_method [string]" 4
957 .IX Item "preview_images_method [string]"
958 Set the preview image method. Supported methods: w3m, iterm2, urxvt,
959 urxvt-full, terminology.  See \fI\s-1PREVIEWS\s0\fR section.
960 .IP "preview_max_size [int]" 4
961 .IX Item "preview_max_size [int]"
962 Avoid previewing files that exceed a certain size, in bytes.  Use a value of 0
963 to disable this feature.
964 .IP "preview_script [string, none]" 4
965 .IX Item "preview_script [string, none]"
966 Which script should handle generating previews?  If the file doesn't exist, or
967 use_preview_script is off, ranger will handle previews itself by just printing
968 the content.
969 .IP "relative_current_zero [bool]" 4
970 .IX Item "relative_current_zero [bool]"
971 When line_numbers is set to relative, show 0 on the current line if
972 true or show the absolute number of the current line when false.
973 .IP "save_backtick_bookmark [bool]" 4
974 .IX Item "save_backtick_bookmark [bool]"
975 Save the \f(CW\*(C`\`\*(C'\fR bookmark to disk.  This bookmark is used to switch to the last
976 directory by typing \f(CW\*(C`\`\`\*(C'\fR.
977 .IP "save_console_history [bool]" 4
978 .IX Item "save_console_history [bool]"
979 Should the console history be saved on exit?  If disabled, the console history
980 is reset when you restart ranger.
981 .IP "save_tabs_on_exit [bool]" 4
982 .IX Item "save_tabs_on_exit [bool]"
983 Save all tabs, except the active, on exit? The last saved tabs are restored once
984 when starting the next session. Multiple sessions are stored in a stack and the
985 oldest saved tabs are restored first.
986 .IP "scroll_offset [integer]" 4
987 .IX Item "scroll_offset [integer]"
988 Try to keep this much space between the top/bottom border when scrolling.
989 .IP "shorten_title [integer]" 4
990 .IX Item "shorten_title [integer]"
991 Trim the title of the window if it gets long?  The number defines how many
992 directories are displayed at once. A value of 0 turns off this feature.
993 .IP "show_cursor [bool]" 4
994 .IX Item "show_cursor [bool]"
995 Always show the terminal cursor?
996 .IP "show_hidden_bookmarks [bool]" 4
997 .IX Item "show_hidden_bookmarks [bool]"
998 Show dotfiles in the bookmark preview window? (Type ')
999 .IP "show_hidden [bool] <zh>, <^H>" 4
1000 .IX Item "show_hidden [bool] <zh>, <^H>"
1001 Show hidden files?
1002 .IP "show_selection_in_titlebar [bool]" 4
1003 .IX Item "show_selection_in_titlebar [bool]"
1004 Add the highlighted file to the path in the titlebar
1005 .IP "sort_case_insensitive [bool] <zc>" 4
1006 .IX Item "sort_case_insensitive [bool] <zc>"
1007 Sort case-insensitively?  If true, \*(L"a\*(R" will be listed before \*(L"B\*(R" even though
1008 its \s-1ASCII\s0 value is higher.
1009 .IP "sort_directories_first [bool] <zd>" 4
1010 .IX Item "sort_directories_first [bool] <zd>"
1011 Sort directories first?
1012 .IP "sort_reverse [bool] <or>" 4
1013 .IX Item "sort_reverse [bool] <or>"
1014 Reverse the order of files?
1015 .IP "sort_unicode [bool]" 4
1016 .IX Item "sort_unicode [bool]"
1017 When sorting according to some string, should the unicode characters be
1018 compared, instead of looking at the raw character values to save time?
1019 .IP "sort [string] <oa>, <ob>, <oc>, <oe>, <om>, <on>, <ot>, <os>, <oz>" 4
1020 .IX Item "sort [string] <oa>, <ob>, <oc>, <oe>, <om>, <on>, <ot>, <os>, <oz>"
1021 Which sorting mechanism should be used?  Choose one of \fBatime\fR, \fBbasename\fR,
1022 \&\fBctime\fR, \fBextension\fR, \fBmtime\fR, \fBnatural\fR, \fBtype\fR, \fBsize\fR, \fBrandom\fR
1024 Note: You can reverse the order by typing an uppercase second letter in the key
1025 combination, e.g. \*(L"oN\*(R" to sort from Z to A.
1026 .IP "status_bar_on_top [bool]" 4
1027 .IX Item "status_bar_on_top [bool]"
1028 Put the status bar at the top of the window?
1029 .IP "tilde_in_titlebar [bool]" 4
1030 .IX Item "tilde_in_titlebar [bool]"
1031 Abbreviate \f(CW$HOME\fR with ~ in the titlebar (first line) of ranger?
1032 .IP "unicode_ellipsis [bool]" 4
1033 .IX Item "unicode_ellipsis [bool]"
1034 Use a unicode \*(L"...\*(R" character instead of \*(L"~\*(R" to mark cut-off filenames?
1035 .IP "bidi_support [bool]" 4
1036 .IX Item "bidi_support [bool]"
1037 Try to properly display file names in \s-1RTL\s0 languages (Hebrew, Arabic) by using
1038 a \s-1BIDI\s0 algorithm to reverse the relevant parts of the text.
1039 Requires the python-bidi pip package.
1040 .IP "update_title [bool]" 4
1041 .IX Item "update_title [bool]"
1042 Set a window title?
1043 .IP "update_tmux_title [bool]" 4
1044 .IX Item "update_tmux_title [bool]"
1045 Set the title to \*(L"ranger\*(R" in the tmux program?
1046 .IP "use_preview_script [bool] <zv>" 4
1047 .IX Item "use_preview_script [bool] <zv>"
1048 Use the preview script defined in the setting \fIpreview_script\fR?
1049 .IP "vcs_aware [bool]" 4
1050 .IX Item "vcs_aware [bool]"
1051 Gather and display data about version control systems. Supported vcs: git, hg.
1052 .IP "vcs_backend_git, vcs_backend_hg, vcs_backend_bzr, vcs_backend_svn [string]" 4
1053 .IX Item "vcs_backend_git, vcs_backend_hg, vcs_backend_bzr, vcs_backend_svn [string]"
1054 Sets the state for the version control backend. The possible values are:
1056 .Vb 3
1057 \& disabled   don\*(Aqt display any information.
1058 \& local      display only local state.
1059 \& enabled    display both, local and remote state. May be slow for hg and bzr.
1061 .IP "viewmode [string]" 4
1062 .IX Item "viewmode [string]"
1063 Sets the view mode, which can be \fBmiller\fR to display the files in the
1064 traditional miller column view that shows multiple levels of the hierarchy, or
1065 \&\fBmultipane\fR to use multiple panes (one per tab) similar to midnight-commander.
1066 .IP "w3m_delay [float]" 4
1067 .IX Item "w3m_delay [float]"
1068 Delay in seconds before displaying an image with the w3m method.
1069 Increase it in case of experiencing display corruption.
1070 .IP "wrap_scroll [bool]" 4
1071 .IX Item "wrap_scroll [bool]"
1072 Enable scroll wrapping \- moving down while on the last item will wrap around to
1073 the top and vice versa.
1074 .IP "xterm_alt_key [bool]" 4
1075 .IX Item "xterm_alt_key [bool]"
1076 Enable this if key combinations with the Alt Key don't work for you.
1077 (Especially on xterm)
1078 .SH "COMMANDS"
1079 .IX Header "COMMANDS"
1080 You can enter the commands in the console which is opened by pressing \*(L":\*(R".
1082 You can always get a list of the currently existing commands by typing \*(L"2?\*(R" in
1083 ranger.  For your convenience, this is a list of the \*(L"public\*(R" commands including their parameters, excluding descriptions:
1085 .Vb 10
1086 \& alias [newcommand] [oldcommand]
1087 \& bulkrename
1088 \& cd [path]
1089 \& chain command1[; command2[; command3...]]
1090 \& chmod octal_number
1091 \& cmap key command
1092 \& console [\-pSTARTPOSITION] command
1093 \& copycmap key newkey [newkey2...]
1094 \& copymap key newkey [newkey2...]
1095 \& copypmap key newkey [newkey2...]
1096 \& copytmap key newkey [newkey2...]
1097 \& cunmap keys...
1098 \& default_linemode [path=regexp | tag=tags] linemodename
1099 \& delete
1100 \& echo [text]
1101 \& edit [filename]
1102 \& eval [\-q] python_code
1103 \& filter [string]
1104 \& filter_inode_type [dfl]
1105 \& find pattern
1106 \& flat level
1107 \& grep pattern
1108 \& help
1109 \& jump_non [\-FLAGS...]
1110 \& linemode linemodename
1111 \& load_copy_buffer
1112 \& map key command
1113 \& mark pattern
1114 \& mark_tag [tags]
1115 \& meta key value
1116 \& mkdir dirname
1117 \& open_with [application] [flags] [mode]
1118 \& pmap key command
1119 \& prompt_metadata [key1 [key2 [...]]]
1120 \& punmap keys...
1121 \& quit
1122 \& quit!
1123 \& quitall
1124 \& quitall!
1125 \& relink newpath
1126 \& rename_append [\-FLAGS...]
1127 \& rename newname
1128 \& save_copy_buffer
1129 \& scout [\-FLAGS...] pattern
1130 \& search pattern
1131 \& search_inc pattern
1132 \& set option value
1133 \& setintag tags option value
1134 \& setlocal [path=<path>] option value
1135 \& shell [\-FLAGS...] command
1136 \& source filename
1137 \& terminal
1138 \& tmap key command
1139 \& touch filename
1140 \& travel pattern
1141 \& tunmap keys...
1142 \& unmap keys...
1143 \& unmark pattern
1144 \& unmark_tag [tags]
1147 There are additional commands which are directly translated to python
1148 functions, one for every method in the ranger.core.actions.Actions class.
1149 They are not documented here, since they are mostly for key bindings, not to be
1150 typed in by a user.  Read the source if you are interested in them.
1152 These are the public commands including their descriptions:
1153 .IP "alias [\fInewcommand\fR] [\fIoldcommand\fR]" 2
1154 .IX Item "alias [newcommand] [oldcommand]"
1155 Copies the oldcommand as newcommand.
1156 .IP "bulkrename" 2
1157 .IX Item "bulkrename"
1158 This command opens a list of selected files in an external editor.  After you
1159 edit and save the file, it will generate a shell script which does bulk
1160 renaming according to the changes you did in the file.
1162 This shell script is opened in an editor for you to review.  After you close
1163 it, it will be executed.
1164 .IP "cd [\fIpath\fR]" 2
1165 .IX Item "cd [path]"
1166 The cd command changes the directory.  If path is a file, selects that file.
1167 The command \f(CW\*(C`:cd \-\*(C'\fR is equivalent to typing ``.
1168 .IP "chain \fIcommand1\fR[; \fIcommand2\fR[; \fIcommand3\fR...]]" 2
1169 .IX Item "chain command1[; command2[; command3...]]"
1170 Combines multiple commands into one, separated by semicolons.
1171 .IP "chmod \fIoctal_number\fR" 2
1172 .IX Item "chmod octal_number"
1173 Sets the permissions of the selection to the octal number.
1175 The octal number is between 000 and 777. The digits specify the permissions for
1176 the user, the group and others.  A 1 permits execution, a 2 permits writing, a
1177 4 permits reading.  Add those numbers to combine them. So a 7 permits
1178 everything.
1180 Key bindings in the form of [\-+]<who><what> and <octal>= also exist.  For
1181 example, \fB+ar\fR allows reading for everyone, \-ow forbids others to write and
1182 777= allows everything.
1184 See also: man 1 chmod
1185 .IP "cmap \fIkey\fR \fIcommand\fR" 2
1186 .IX Item "cmap key command"
1187 Binds keys for the console. Works like the \f(CW\*(C`map\*(C'\fR command.
1188 .IP "console [\-p\fIN\fR] \fIcommand\fR" 2
1189 .IX Item "console [-pN] command"
1190 Opens the console with the command already typed in.  The cursor is placed at
1191 \&\fIN\fR.
1192 .IP "copycmap \fIkey\fR \fInewkey\fR [\fInewkey2\fR ...]" 2
1193 .IX Item "copycmap key newkey [newkey2 ...]"
1194 See \f(CW\*(C`copymap\*(C'\fR
1195 .IP "copymap \fIkey\fR \fInewkey\fR [\fInewkey2\fR ...]" 2
1196 .IX Item "copymap key newkey [newkey2 ...]"
1197 Copies the keybinding \fIkey\fR to \fInewkey\fR in the \*(L"browser\*(R" context.  This is a
1198 deep copy, so if you change the new binding (or parts of it) later, the old one
1199 is not modified.
1201 To copy key bindings of the console, taskview, or pager use \*(L"copycmap\*(R",
1202 \&\*(L"copytmap\*(R" or \*(L"copypmap\*(R".
1203 .IP "copypmap \fIkey\fR \fInewkey\fR [\fInewkey2\fR ...]" 2
1204 .IX Item "copypmap key newkey [newkey2 ...]"
1205 See \f(CW\*(C`copymap\*(C'\fR
1206 .IP "copytmap \fIkey\fR \fInewkey\fR [\fInewkey2\fR ...]" 2
1207 .IX Item "copytmap key newkey [newkey2 ...]"
1208 See \f(CW\*(C`copymap\*(C'\fR
1209 .IP "cunmap [\fIkeys...\fR]" 2
1210 .IX Item "cunmap [keys...]"
1211 Removes key mappings of the console. Works like the \f(CW\*(C`unmap\*(C'\fR command.
1212 .IP "default_linemode [\fIpath=regexp\fR | \fItag=tags\fR] \fIlinemodename\fR" 2
1213 .IX Item "default_linemode [path=regexp | tag=tags] linemodename"
1214 Sets the default linemode.  See \fIlinemode\fR command.
1216 Examples:
1218 Set the global default linemode to \*(L"permissions\*(R":
1219  :default_linemode permissions
1221 Set the default linemode to \*(L"permissions\*(R" for all files tagged with \*(L"p\*(R" or \*(L"P\*(R":
1222  :default_linemode tag=pP permissions
1224 Set the default linemode for all files in ~/books/ to \*(L"metatitle\*(R":
1225  :default_linemode path=/home/.*?/books/.* metatitle
1226 .IP "delete" 2
1227 .IX Item "delete"
1228 Destroy all files in the selection with a roundhouse kick.  ranger will ask for
1229 a confirmation if you attempt to delete multiple (marked) files or non-empty
1230 directories.  This can be changed by modifying the setting \*(L"confirm_on_delete\*(R".
1231 .IP "echo \fItext\fR" 2
1232 .IX Item "echo text"
1233 Display the text in the statusbar.
1234 .IP "edit [\fIfilename\fR]" 2
1235 .IX Item "edit [filename]"
1236 Edit the current file or the file in the argument.
1237 .IP "eval [\fI\-q\fR] \fIpython_code\fR" 2
1238 .IX Item "eval [-q] python_code"
1239 Evaluates the python code.  `fm' is a reference to the \s-1FM\s0 instance.  To display
1240 text, use the function `p'.  The result is displayed on the screen unless you
1241 use the \*(L"\-q\*(R" option.
1243 Examples:
1244  :eval fm
1245  :eval len(fm.tabs)
1246  :eval p(\*(L"Hello World!\*(R")
1247 .IP "filter [\fIstring\fR]" 2
1248 .IX Item "filter [string]"
1249 Displays only the files which contain the \fIstring\fR in their basename.  Running
1250 this command without any parameter will reset the filter.
1252 This command is based on the \fIscout\fR command and supports all of its options.
1253 .IP "filter_inode_type [dfl]" 2
1254 .IX Item "filter_inode_type [dfl]"
1255 Displays only the files of specified inode type. To display only directories,
1256 use the 'd' parameter. To display only files, use the 'f' parameter. To display
1257 only links, use the 'l' parameter. Parameters can be combined. To remove this
1258 filter, use no parameter.
1259 .IP "find \fIpattern\fR" 2
1260 .IX Item "find pattern"
1261 Search files in the current directory that contain the given (case-insensitive)
1262 string in their name as you type.  Once there is an unambiguous result, it will
1263 be run immediately. (Or entered, if it's a directory.)
1265 This command is based on the \fIscout\fR command and supports all of its options.
1266 .IP "flat level" 2
1267 .IX Item "flat level"
1268 Flattens the directory view up to the specified level. Level \-1 means infinite
1269 level. Level 0 means standard view without flattened directory view. Level
1270 values \-2 and less are invalid.
1271 .IP "grep \fIpattern\fR" 2
1272 .IX Item "grep pattern"
1273 Looks for a string in all marked files or directories.
1274 .IP "help" 2
1275 .IX Item "help"
1276 Provides a quick way to view ranger documentations.
1277 .IP "jump_non [\-\fIflags\fR...]" 2
1278 .IX Item "jump_non [-flags...]"
1279 Jumps to first non-directory if highlighted file is a directory and vice versa.
1281 Flags:
1282  \-r    Jump in reverse order
1283  \-w    Wrap around if reaching end of filelist
1284 .IP "linemode \fIlinemodename\fR" 2
1285 .IX Item "linemode linemodename"
1286 Sets the linemode of all files in the current directory.  The linemode may be:
1288 .Vb 6
1289 \& "filename": display each line as "<basename>...<size>"
1290 \& "fileinfo": display each line as "<basename>...<file(1) output>"
1291 \& "permissions": display each line as "<permissions> <owner> <group> <basename>"
1292 \& "metatitle": display metadata from .metadata.json files if
1293 \&     available, fall back to the "filename" linemode if no
1294 \&     metadata was found.  See :meta command.
1297 The custom linemodes may be added by subclassing the \fILinemodeBase\fR class.
1298 See the \fIranger.core.linemode\fR module for some examples.
1299 .IP "load_copy_buffer" 2
1300 .IX Item "load_copy_buffer"
1301 Load the copy buffer from \fI~/.config/ranger/copy_buffer\fR.  This can be used to
1302 pass the list of copied files to another ranger instance.
1303 .IP "map \fIkey\fR \fIcommand\fR" 2
1304 .IX Item "map key command"
1305 Assign the key combination to the given command.  Whenever you type the
1306 key/keys, the command will be executed.  Additionally, if you use a quantifier
1307 when typing the key, like 5j, it will be passed to the command as the attribute
1308 \&\*(L"self.quantifier\*(R".
1310 The keys you bind with this command are accessible in the file browser only,
1311 not in the console, task view or pager.  To bind keys there, use the commands
1312 \&\*(L"cmap\*(R", \*(L"tmap\*(R" or \*(L"pmap\*(R".
1313 .IP "mark \fIpattern\fR" 2
1314 .IX Item "mark pattern"
1315 Mark all files matching the regular expression pattern.
1317 This command is based on the \fIscout\fR command and supports all of its options.
1318 .IP "mark_tag [\fItags\fR]" 2
1319 .IX Item "mark_tag [tags]"
1320 Mark all tags that are tagged with either of the given tags.  When leaving out
1321 the tag argument, all tagged files are marked.
1322 .IP "meta \fIkey\fR \fIvalue\fR" 2
1323 .IX Item "meta key value"
1324 Set the metadata of the currently highlighted file.  Example:
1326 .Vb 2
1327 \& :meta title The Hitchhiker\*(Aqs Guide to the Galaxy
1328 \& :meta year 1979
1331 This metadata can be displayed by, for example, using the \*(L"metatitle\*(R" line mode
1332 by typing Mt.
1333 .IP "mkdir \fIdirname\fR" 2
1334 .IX Item "mkdir dirname"
1335 Creates a directory with the name \fIdirname\fR.
1336 .IP "open_with [\fIapplication\fR] [\fIflags\fR] [\fImode\fR]" 2
1337 .IX Item "open_with [application] [flags] [mode]"
1338 Open the selected files with the given application, unless it is omitted, in
1339 which case the default application is used.  \fIflags\fR change the way the
1340 application is executed and are described in their own section in this man
1341 page.  The \fImode\fR is a number that specifies which application to use.  The list
1342 of applications is generated by the external file opener \*(L"rifle\*(R" and can be
1343 displayed when pressing \*(L"r\*(R" in ranger.
1345 Note that if you specify an application, the mode is ignored.
1346 .IP "pmap \fIkey\fR \fIcommand\fR" 2
1347 .IX Item "pmap key command"
1348 Binds keys for the pager. Works like the \f(CW\*(C`map\*(C'\fR command.
1349 .IP "prompt_metadata [\fIkeys ...\fR]" 2
1350 .IX Item "prompt_metadata [keys ...]"
1351 Prompt the user to input metadata with the \f(CW\*(C`meta\*(C'\fR command for multiple keys in
1352 a row.
1353 .IP "punmap [\fIkeys ...\fR]" 2
1354 .IX Item "punmap [keys ...]"
1355 Removes key mappings of the pager. Works like the \f(CW\*(C`unmap\*(C'\fR command.
1356 .IP "quit" 2
1357 .IX Item "quit"
1358 Closes the current tab, if there's only one tab. Otherwise quits if there are no tasks in progress.
1359 The current directory will be bookmarked as ' so you can re-enter it by typing `` or '' the next time you
1360 start ranger.
1361 .IP "quit!" 2
1362 .IX Item "quit!"
1363 Like \f(CW\*(C`quit\*(C'\fR, except will force quit even if tasks are in progress.
1364 .IP "quitall" 2
1365 .IX Item "quitall"
1366 Like \f(CW\*(C`quit\*(C'\fR, except will quit even if multiple tabs are open.
1367 .IP "quitall!" 2
1368 .IX Item "quitall!"
1369 Like \f(CW\*(C`quitall\*(C'\fR, except will force quit even if tasks are in progress.
1370 .IP "relink \fInewpath\fR" 2
1371 .IX Item "relink newpath"
1372 Change the link destination of the current symlink file to <newpath>. First
1373 <tab> will load the original link.
1374 .IP "rename \fInewname\fR" 2
1375 .IX Item "rename newname"
1376 Rename the current file.  If a file with that name already exists, the renaming
1377 will fail.  Also try the key binding A for appending something to a file name.
1378 .IP "rename_append [\-\fIflags\fR...]" 2
1379 .IX Item "rename_append [-flags...]"
1380 Opens the console with \*(L":rename <current file>\*(R" with the cursor positioned
1381 before the file extension.
1383 Flags:
1384  \-a    Position before all extensions
1385  \-r    Remove everything before extensions
1386 .IP "save_copy_buffer" 2
1387 .IX Item "save_copy_buffer"
1388 Save the copy buffer to \fI~/.config/ranger/copy_buffer\fR.  This can be used to
1389 pass the list of copied files to another ranger instance.
1390 .IP "scout [\-\fIflags\fR...] [\-\-] \fIpattern\fR" 2
1391 .IX Item "scout [-flags...] [--] pattern"
1392 Swiss army knife command for searching, traveling and filtering files.
1394 Flags:
1395  \-a    Automatically open a file on unambiguous match
1396  \-e    Open the selected file when pressing enter
1397  \-f    Filter files that match the current search pattern
1398  \-g    Interpret pattern as a glob pattern
1399  \-i    Ignore the letter case of the files
1400  \-k    Keep the console open when changing a directory with the command
1401  \-l    Letter skipping; e.g. allow \*(L"rdme\*(R" to match the file \*(L"readme\*(R"
1402  \-m    Mark the matching files after pressing enter
1403  \-M    Unmark the matching files after pressing enter
1404  \-p    Permanent filter: hide non-matching files after pressing enter
1405  \-r    Interpret pattern as a regular expression pattern
1406  \-s    Smart case; like \-i unless pattern contains upper case letters
1407  \-t    Apply filter and search pattern as you type
1408  \-v    Inverts the match
1410 Multiple flags can be combined.  For example, \*(L":scout \-gpt\*(R" would create
1411 a :filter\-like command using globbing.
1412 .IP "search \fIpattern\fR" 2
1413 .IX Item "search pattern"
1414 Search files in the current directory that match the given (case insensitive)
1415 regular expression pattern.
1417 This command is based on the \fIscout\fR command and supports all of its options.
1418 .IP "search_inc \fIpattern\fR" 2
1419 .IX Item "search_inc pattern"
1420 Search files in the current directory that match the given (case insensitive)
1421 regular expression pattern.  This command gets you to matching files as you
1422 type.
1424 This command is based on the \fIscout\fR command and supports all of its options.
1425 .IP "set \fIoption\fR \fIvalue\fR" 2
1426 .IX Item "set option value"
1427 Assigns a new value to an option.  Valid options are listed in the settings
1428 section.  Use tab completion to get the current value of an option, though this
1429 doesn't work for functions and regular expressions. Valid values are:
1431 .Vb 7
1432 \& setting type   | example values
1433 \& \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-
1434 \& bool           | true, false
1435 \& integer        | 1, 23, 1337
1436 \& string         | foo, hello world
1437 \& list           | 1,2,3,4
1438 \& none           | none
1440 .IP "setintag \fItags\fR \fIoption\fR \fIvalue\fR" 2
1441 .IX Item "setintag tags option value"
1442 Assigns a new value to an option, but locally for the directories that are
1443 marked with \fItag\fR.  This means, that this option only takes effect when
1444 visiting that directory.
1446 For example, to change the sorting order in your downloads directory, tag it
1447 with the \fIv\fR tag by typing \fI"v\fR, then use this command:
1449 .Vb 1
1450 \& setintag v sort ctime
1452 .IP "setlocal [path=\fIpath\fR] \fIoption\fR \fIvalue\fR" 2
1453 .IX Item "setlocal [path=path] option value"
1454 Assigns a new value to an option, but locally for the directory given by
1455 \&\fIpath\fR. This means, that this option only takes effect when visiting that
1456 directory. If no path is given, uses the current directory.
1458 \&\fIpath\fR is a regular expression.  This means that \f(CW\*(C`path=~/dl\*(C'\fR applies to all
1459 paths that start with \fI~/dl\fR, e.g. \fI~/dl2\fR and \fI~/dl/foo\fR. To avoid this,
1460 use \f(CW\*(C`path=~/dl$\*(C'\fR.
1462 \&\fIpath\fR can be quoted with either single or double quotes to prevent unwanted
1463 splitting. \fIpath='~/dl dl$'\fR or \fIpath=\*(L"~/dl dl$\*(R"\fR
1464 .IP "shell [\-\fIflags\fR] \fIcommand\fR" 2
1465 .IX Item "shell [-flags] command"
1466 Run a shell command.  \fIflags\fR are discussed in their own section.
1467 .IP "source \fIfilename\fR" 2
1468 .IX Item "source filename"
1469 Reads commands from a file and executes them in the ranger console.
1471 This can be used to re-evaluate the rc.conf file after changing it:
1473 .Vb 1
1474 \& map X chain shell vim \-p %confdir/rc.conf %rangerdir/config/rc.conf; source %confdir/rc.conf
1476 .IP "terminal" 2
1477 .IX Item "terminal"
1478 Spawns the \fIx\-terminal-emulator\fR starting in the current directory.
1479 .IP "tmap \fIkey\fR \fIcommand\fR" 2
1480 .IX Item "tmap key command"
1481 Binds keys for the taskview. Works like the \f(CW\*(C`map\*(C'\fR command.
1482 .IP "touch \fIfilename\fR" 2
1483 .IX Item "touch filename"
1484 Creates an empty file with the name \fIfilename\fR, unless it already exists.
1485 .IP "travel \fIpattern\fR" 2
1486 .IX Item "travel pattern"
1487 Filters the current directory for files containing the letters in the
1488 string, possibly with other letters in between.  The filter is applied as
1489 you type.  When only one directory is left, it is entered and the console
1490 is automatically reopened, allowing for fast travel.
1491 To close the console, press \s-1ESC\s0 or execute a file.
1493 This command is based on the \fIscout\fR command and supports all of its options.
1494 .IP "tunmap [\fIkeys ...\fR]" 2
1495 .IX Item "tunmap [keys ...]"
1496 Removes key mappings of the taskview. Works like the \f(CW\*(C`unmap\*(C'\fR command.
1497 .IP "unmap [\fIkeys\fR ...]" 2
1498 .IX Item "unmap [keys ...]"
1499 Removes the given key mappings in the \*(L"browser\*(R" context.  To unmap key bindings
1500 in the console, taskview, or pager use \*(L"cunmap\*(R", \*(L"tunmap\*(R" or \*(L"punmap\*(R".
1501 .IP "unmark \fIpattern\fR" 2
1502 .IX Item "unmark pattern"
1503 Unmark all files matching a regular expression pattern.
1505 This command is based on the \fIscout\fR command and supports all of its options.
1506 .IP "unmark_tag [\fItags\fR]" 2
1507 .IX Item "unmark_tag [tags]"
1508 Unmark all tags that are tagged with either of the given tags.  When leaving
1509 out the tag argument, all tagged files are unmarked.
1510 .SH "FILES"
1511 .IX Header "FILES"
1512 ranger reads several configuration files which are located in
1513 \&\fI\f(CI$HOME\fI/.config/ranger\fR or \fI\f(CI$XDG_CONFIG_HOME\fI/ranger\fR if \f(CW$XDG_CONFIG_HOME\fR is
1514 defined.  You can use the \-\-copy\-config option to obtain the default
1515 configuration files.  The files contain further documentation.
1517 \&\fIrc.conf\fR, \fIcommands.py\fR and \fIcolorschemes\fR do not need to be copied fully
1518 as they will only be adding to the default configuration files except if explicitly
1519 overridden. This may lead to some confusing situations, for example when a key is
1520 being bound despite the corresponding line being removed from the user's copy of
1521 the configuration file. This behavior may be disabled with an environment
1522 variable (see also: \fB\s-1ENVIRONMENT\s0\fR). Note: All other configuration files only
1523 read from one source; i.e. default \s-1OR\s0 user, not both.
1524 \&\fIrc.conf\fR and \fIcommands.py\fR are additionally read from \fI/etc/ranger\fR if they
1525 exist for system-wide configuration, user configuration overrides system
1526 configuration which overrides the default configuration.
1528 When starting ranger with the \fB\-\-clean\fR option, it will not access or create
1529 any of these files.
1530 .SS "\s-1CONFIGURATION\s0"
1531 .IX Subsection "CONFIGURATION"
1532 .IP "rc.conf" 10
1533 .IX Item "rc.conf"
1534 Contains a list of commands which are executed on startup.  Mostly key bindings
1535 and settings are defined here.
1536 .IP "commands.py" 10
1537 .IX Item "commands.py"
1538 A python module that defines commands which can be used in ranger's console by
1539 typing \*(L":\*(R" or in the rc.conf file.  Note that you can define commands in the
1540 same manner within plugins.
1541 .IP "commands_full.py" 10
1542 .IX Item "commands_full.py"
1543 This file is copied by \-\-copy\-config=commands_full and serves as a reference
1544 for custom commands.  It is entirely ignored by ranger.
1545 .IP "rifle.conf" 10
1546 .IX Item "rifle.conf"
1547 This is the configuration file for the built-in file launcher called \*(L"rifle\*(R".
1548 .IP "scope.sh" 10
1549 .IX Item "scope.sh"
1550 This is a script that handles file previews.  When the options
1551 \&\fIuse_preview_script\fR and \fIpreview_files\fR are set, the program specified in
1552 the option \fIpreview_script\fR is run and its output and/or exit code determines
1553 rangers reaction.
1554 .IP "colorschemes/" 10
1555 .IX Item "colorschemes/"
1556 Colorschemes can be placed here.
1557 .IP "plugins/" 10
1558 .IX Item "plugins/"
1559 Plugins can be placed here.
1560 .SS "\s-1STORAGE\s0"
1561 .IX Subsection "STORAGE"
1562 .IP "bookmarks" 10
1563 .IX Item "bookmarks"
1564 This file contains a list of bookmarks.  The syntax is /^(.):(.*)$/. The first
1565 character is the bookmark key and the rest after the colon is the path to the
1566 file.  In ranger, bookmarks can be set by typing m<key>, accessed by typing
1567 \&'<key> and deleted by typing um<key>.
1568 .IP "copy_buffer" 10
1569 .IX Item "copy_buffer"
1570 When running the command :save_copy_buffer, the paths of all currently copied
1571 files are saved in this file.  You can later run :load_copy_buffer to copy the
1572 same files again, pass them to another ranger instance or process them in a
1573 script.
1574 .IP "history" 10
1575 .IX Item "history"
1576 Contains a list of commands that have been previously typed in.
1577 .IP "tagged" 10
1578 .IX Item "tagged"
1579 Contains a list of tagged files. The syntax is /^(.:)?(.*)$/ where the first
1580 letter is the optional name of the tag and the rest after the optional colon is
1581 the path to the file.  In ranger, tags can be set by pressing t and removed
1582 with T.  To assign a named tag, type "<tagname>.
1583 .SH "ENVIRONMENT"
1584 .IX Header "ENVIRONMENT"
1585 These environment variables have an effect on ranger:
1586 .IP "\s-1RANGER_LEVEL\s0" 8
1587 .IX Item "RANGER_LEVEL"
1588 ranger sets this environment variable to \*(L"1\*(R" or increments it if it already
1589 exists.  External programs can determine whether they were spawned from ranger
1590 by checking for this variable.
1591 .IP "\s-1RANGER_LOAD_DEFAULT_RC\s0" 8
1592 .IX Item "RANGER_LOAD_DEFAULT_RC"
1593 If this variable is set to \s-1FALSE,\s0 ranger will not load the default rc.conf.
1594 This can save time if you copied the whole rc.conf to ~/.config/ranger/ and
1595 don't need the default one at all.
1596 .IP "\s-1VISUAL\s0" 8
1597 .IX Item "VISUAL"
1598 Defines the editor to be used for the \*(L"E\*(R" key.  Falls back to \s-1EDITOR\s0 if
1599 undefined or empty.
1600 .IP "\s-1EDITOR\s0" 8
1601 .IX Item "EDITOR"
1602 Defines the editor to be used for the \*(L"E\*(R" key if \s-1VISUAL\s0 is undefined or empty.
1603 Defaults to \*(L"vim\*(R".
1604 .IP "\s-1SHELL\s0" 8
1605 .IX Item "SHELL"
1606 Defines the shell that ranger is going to use with the :shell command and
1607 the \*(L"S\*(R" key.  Defaults to \*(L"/bin/sh\*(R".
1608 .IP "\s-1TERMCMD\s0" 8
1609 .IX Item "TERMCMD"
1610 Defines the terminal emulator command that ranger is going to use with the
1611 :terminal command and the \*(L"t\*(R" run flag.  Defaults to \*(L"xterm\*(R".
1612 .IP "\s-1XDG_CONFIG_HOME\s0" 8
1613 .IX Item "XDG_CONFIG_HOME"
1614 Specifies the directory for configuration files. Defaults to \fI\f(CI$HOME\fI/.config\fR.
1615 .IP "\s-1PYTHONOPTIMIZE\s0" 8
1616 .IX Item "PYTHONOPTIMIZE"
1617 This variable determines the optimize level of python.
1619 Using PYTHONOPTIMIZE=1 (like python \-O) will make python discard assertion
1620 statements.  You will gain efficiency at the cost of losing some debug info.
1622 Using PYTHONOPTIMIZE=2 (like python \-OO) will additionally discard any
1623 docstrings.  Using this will disable the <F1> key on commands.
1624 .IP "W3MIMGDISPLAY_PATH" 8
1625 .IX Item "W3MIMGDISPLAY_PATH"
1626 By changing this variable, you can change the path of the executable file for
1627 image previews.  By default, it is set to \fI/usr/lib/w3m/w3mimgdisplay\fR.
1628 .SH "EXAMPLES"
1629 .IX Header "EXAMPLES"
1630 There are various examples on how to extend ranger with plugins or combine
1631 ranger with other programs.  These can be found in the
1632 \&\fI/usr/share/doc/ranger/examples/\fR directory, or the \fIdoc/ranger/\fR that is
1633 provided along with the source code.
1634 .SH "LICENSE"
1635 .IX Header "LICENSE"
1636 \&\s-1GNU\s0 General Public License 3 or (at your option) any later version.
1637 .SH "LINKS"
1638 .IX Header "LINKS"
1639 .IP "Download: <https://ranger.github.io/ranger\-stable.tar.gz>" 4
1640 .IX Item "Download: <https://ranger.github.io/ranger-stable.tar.gz>"
1641 .PD 0
1642 .IP "The project page: <https://ranger.github.io/>" 4
1643 .IX Item "The project page: <https://ranger.github.io/>"
1644 .IP "The mailing list: <https://savannah.nongnu.org/mail/?group=ranger>" 4
1645 .IX Item "The mailing list: <https://savannah.nongnu.org/mail/?group=ranger>"
1646 .IP "\s-1IRC\s0 channel: #ranger on freenode.net" 4
1647 .IX Item "IRC channel: #ranger on freenode.net"
1650 ranger is maintained with the git version control system.  To fetch a fresh
1651 copy, run:
1653 .Vb 1
1654 \& git clone git://git.savannah.nongnu.org/ranger.git
1656 .SH "SEE ALSO"
1657 .IX Header "SEE ALSO"
1658 \&\fBrifle\fR\|(1)
1659 .SH "BUGS"
1660 .IX Header "BUGS"
1661 Report bugs here: <https://github.com/ranger/ranger/issues>
1663 Please include as much relevant information as possible.  For the most
1664 diagnostic output, run ranger like this: \f(CW\*(C`PYTHONOPTIMIZE= ranger \-\-debug\*(C'\fR