Ticket #2848: fixup of user-defined keymap load.
[midnight-commander.git] / doc / man / mc.1.in
blob1ac90b0a5c8dd712302d01d4ac34c5cb1e741ca7
1 .\"TOPICS "Topics:"
2 .TH MC 1 "%DATE_OF_MAN_PAGE%" "MC Version %DISTR_VERSION%" "GNU Midnight Commander"
3 .\"SKIP_SECTION"
4 .SH "NAME"
5 mc \- Visual shell for Unix\-like systems.
6 .\"SKIP_SECTION"
7 .SH "USAGE"
8 .B mc
9 [\-abcCdfhPstuUVx] [\-l log] [dir1 [dir2]] [\-e [file] ...] [\-v file]
10 .\"NODE "DESCRIPTION"
11 .SH "DESCRIPTION"
12 GNU Midnight Commander is a directory browser/file manager for
13 Unix\-like operating systems.
14 .\"NODE "OPTIONS"
15 .\"DONT_SPLIT"
16 .SH "OPTIONS"
17 .TP
18 .I \-a, \-\-stickchars
19 Disable usage of graphic characters for line drawing.
20 .TP
21 .I \-b, \-\-nocolor
22 Force black and white display.
23 .TP
24 .I \-c, \-\-color
25 Force color mode, please check the section
26 .\"LINK2"
27 Colors
28 .\"Colors"
29 for more information.
30 .TP
31 .I \-C arg, \-\-colors=arg
32 Specify a different color set in the command line.  The format of arg is
33 documented in the
34 .\"LINK2"
35 Colors
36 .\"Colors"
37 section.
38 .TP
39 .I \-S arg
40 Specify a name of skin in the command line. Technology of skins is
41 documented in the
42 .\"LINK2"
43 Skins\&.
44 .\"Skins"
45 section.
46 .TP
47 .I \-d, \-\-nomouse
48 Disable mouse support.
49 .TP
50 .I \-e [file], \-\-edit[=file]
51 Start the internal editor.  If the file is specified, open it on
52 startup.  See also
53 .BR "mcedit (1)" .
54 .TP
55 .I \-f, \-\-datadir
56 Display the compiled\-in search paths for Midnight Commander files.
57 .TP
58 .I \-F, \-\-datadir\-info
59 Display extended info about compiled\-in paths for
60 Midnight Commander.
61 .TP
62 .I \-\-configure\-options
63 Display configure options.
64 .TP
65 .I \-k, \-\-resetsoft
66 Reset softkeys to their default from the termcap/terminfo
67 database. Only useful on HP terminals when the function keys don't work.
68 .TP
69 .I \-K file, \-\-keymap=file
70 Specify a name of keymap file in the command line.
71 .TP
72 .I \-\-nokeymap
73 Don't load key bindings from any file, use default hardcoded keys.
74 .TP
75 .I \-l file, \-\-ftplog=file
76 Save the ftpfs dialog with the server in file.
77 .TP
78 .I \-P file, \-\-printwd=file
79 Print the last working directory to the specified file.  This option is
80 not meant to be used directly.  Instead, it's used from a special shell
81 script that automatically changes the current directory of the shell to
82 the last directory the Midnight Commander was in.  Source the file
83 .B %prefix%/share/mc/bin/mc.sh
84 (bash and zsh users) or
85 .B %prefix%/share/mc/bin/mc.csh
86 (tcsh users) respectively to define
87 .B mc
88 as an alias to the appropriate shell script.
89 .TP
90 .I \-s
91 Set alternative mode drawing of frameworks.
92 If the section [Lines] is not filled, the symbol for the pseudographics
93 frame is a space, otherwise the frame characters are taken from follow params.
95 .B You can redefine the following variables:
96 .TP
97 .B lefttop
98 left\-top corner
99 .TP
100 .B righttop
101 right\-top corner
103 .B centertop
104 center\-top cross
106 .B centerbottom
107 center\-bottom cross
109 .B leftbottom
110 left\-bottom corner
112 .B rightbottom
113 right\-bottom corner
115 .B leftmiddle
116 left\-middle cross
118 .B rightmiddle
119 right\-middle cross
121 .B centermiddle
122 center cross
124 .B horiz
125 default horizontal line
127 .B vert
128 default vertical line
130 .B thinhoriz
131 thin horizontal line
133 .B thinvert
134 thin vertical line
136 .I \-t, \-\-termcap
137 Used only if the code was compiled with Slang and terminfo: it makes
138 the Midnight Commander use the value of the
139 .B TERMCAP
140 variable for the terminal information instead of the information on
141 the system wide terminal database
143 .I \-u, \-\-nosubshell
144 Disable use of the concurrent shell (only makes sense if the Midnight
145 Commander has been built with concurrent shell support).
147 .I \-U, \-\-subshell
148 Enable use of the concurrent shell support (only makes sense if the
149 Midnight Commander was built with the subshell support set as an
150 optional feature).
152 .I \-v file, \-\-view=file
153 Start the internal viewer to view the specified file.  See also
154 .BR "mcview (1)" .
156 .I \-V, \-\-version
157 Display the version of the program.
159 .I \-x, \-\-xterm
160 Force xterm mode.  Used when running on xterm\-capable terminals (two
161 screen modes, and able to send mouse escape sequences).
163 .I \-X, \-\-no\-x11
164 Do not use X11 to get the state of modifiers Alt, Ctrl, Shift
166 .I \-g, \-\-oldmouse
167 Force a "normal tracking" mouse mode. Used when running on
168 xterm\-capable terminals (tmux/screen).
170 If specified, the first path name is the directory to show in the
171 selected panel; the second path name is the directory to be shown in
172 the other panel.
173 .\"NODE "Overview"
174 .SH "Overview"
175 The screen of the Midnight Commander is divided into four parts.
176 Almost all of the screen space is taken up by two directory panels.
177 By default, the second line from the bottom of the screen is the
178 shell command line, and the bottom line shows the function key labels.
179 The topmost line is the
180 .\"LINK2"
181 menu bar line\&.
182 .\"Menu Bar"
183 The menu bar line may not be visible, but appears if you click the
184 topmost line with the mouse or press the F9 key.
186 The Midnight Commander provides a view of two directories at the same
187 time. One of the panels is the current panel (a selection bar is in
188 the current panel). Almost all operations take place on the current
189 panel. Some file operations like Rename and Copy by default use the
190 directory of the unselected panel as a destination (don't worry, they
191 always ask you for confirmation first). For more information, see the
192 sections on the
193 .\"LINK2"
194 Directory Panels\&,
195 .\"Directory Panels"
197 .\"LINK2"
198 Left and Right Menus
199 .\"Left and Right Menus"
200 and the
201 .\"LINK2"
202 File Menu\&.
203 .\"File Menu"
205 You can execute system commands from the Midnight Commander by simply
206 typing them. Everything you type will appear on the shell command line,
207 and when you press Enter the Midnight Commander will execute the
208 command line you typed; read the
209 .\"LINK2"
210 Shell Command Line
211 .\"Shell Command Line"
213 .\"LINK2"
214 Input Line Keys
215 .\"Input Line Keys"
216 sections to learn more about the command line.
217 .\"NODE "Mouse Support"
218 .SH "Mouse Support"
219 The Midnight Commander comes with mouse support.  It is activated
220 whenever you are running on an
221 .B xterm(1)
222 terminal (it even works if you take a telnet, ssh or rlogin connection to
223 another machine from the xterm) or if you are running on a Linux
224 console and have the
225 .B gpm
226 mouse server running.
228 When you left click on a file in the directory panels, that file is
229 selected; if you click with the right button, the file is marked (or
230 unmarked, depending on the previous state).
232 Double\-clicking on a file will try to execute the command if it is
233 an executable program; and if the
234 .\"LINK2"
235 extension file
236 .\"Extension File Edit"
237 has a program specified for the file's extension, the specified
238 program is executed.
240 Also, it is possible to execute the commands assigned to the function
241 key labels by clicking on them.
243 The default auto repeat rate for the mouse buttons is 400
244 milliseconds. This may be changed to other values by editing the
245 .\"LINK2"
246 \&~/.config/mc/ini
247 .\"Save Setup"
248 file and changing the
249 .I mouse_repeat_rate
250 parameter.
252 If you are running the Midnight Commander with the mouse support, you
253 can get the default mouse behavior (cutting and pasting text) by holding
254 down the Shift key.
255 .SH ""
256 .\"NODE "Keys"
257 .SH "Keys"
258 Some commands in the Midnight Commander involve the use of the
259 .I Control
260 (sometimes labeled CTRL or CTL) and the
261 .I Meta
262 (sometimes labeled ALT or even Compose) keys. In this manual we will
263 use the following abbreviations:
265 .B C\-<chr>
266 means hold the Control key while typing the character <chr>.
267 Thus C\-f would be: hold the Control key and type f.
269 .B Alt\-<chr>
270 means hold the Meta or Alt key down while typing <chr>.
271 If there is no Meta or Alt key, type
272 .IR ESC ,
273 release it, then type the character <chr>.
275 .B S\-<chr>
276 means hold the Shift key down while typing <chr>.
278 All input lines in the Midnight Commander use an approximation to
279 the GNU Emacs editor's key bindings (default).
281 You may redefine key bindings. See
282 .\"LINK2"
283 .I redefine hotkey bindings
284 .\"Keys_redefine"
286 for more info. All other key bindings (described in this manual) relative
287 to default behavior.
290 There are many sections which tell about the keys. The following are
291 the most important.
294 .\"LINK2"
295 File Menu
296 .\"File Menu"
297 section documents the keyboard shortcuts for the commands appearing in
298 the File menu. This section includes the function keys. Most of these
299 commands perform some action, usually on the selected file or the
300 tagged files.
303 .\"LINK2"
304 Directory Panels
305 .\"Directory Panels"
306 section documents the keys which select a file or tag files as a
307 target for a later action (the action is usually one from the file
308 menu).
311 .\"LINK2"
312 Shell Command Line
313 .\"Shell Command Line"
314 section list the keys which are used for entering and editing command
315 lines. Most of these copy file names and such from the directory
316 panels to the command line (to avoid excessive typing) or access the
317 command line history.
319 .\"LINK2"
320 Input Line Keys
321 .\"Input Line Keys"
322 are used for editing input lines. This means both the command line and
323 the input lines in the query dialogs.
325 .\"NODE "  Keys_redefine"
326 .SH "  Redefine hotkey bindings"
327 Hotkey bindings may be read from external file (keymap\-file).
328 Initially, Mignight Commander creates key bindings using keymap defined
329 in the source code. Then, two files
330 .B %prefix%/share/mc/mc.keymap
332 .B %sysconfdir%/mc/mc.keymap
333 are loaded always, sequentially reassigned key bindings defined earlier.
334 User\-defined keymap\-file is searched on the following algorithm (to the first one found):
337 1) command line option
338 .B \-K \<keymap\>
340 .B \-\-keymap=\<keymap\>
342 2) Environment variable
343 .B MC_KEYMAP
345 3) Parameter
346 .B keymap
347 in section
348 .B [Midnight\-Commander]
349 of config file.
351 4) File
352 .B ~/.config/mc/mc.keymap
355 Command line option, environment variable and parameter in config file may
356 contain the absolute path to the keymap\-file (with the extension \.keymap
357 or without it). Search of keymap\-file will occur in (to the first one found):
361 .B ~/.config/mc
364 .B %sysconfdir%/mc/
367 .B %prefix%/share/mc/
369 .\"NODE "  Miscellaneous Keys"
370 .SH "  Miscellaneous Keys"
371 Here are some keys which don't fall into any of the other categories:
373 .B Enter
374 if there is some text in the command line (the one at the bottom of
375 the panels), then that command is executed. If there is no text in the
376 command line then if the selection bar is over a directory the
377 Midnight Commander does a
378 .B chdir(2)
379 to the selected directory and reloads the information on the panel;
380 if the selection is an executable file then it is executed. Finally,
381 if the extension of the selected file name matches one of the
382 extensions in the
383 .\"LINK2"
384 extensions file
385 .\"Extension File Edit"
386 then the corresponding command is executed.
388 .B C\-l
389 repaint all the information in the Midnight Commander.
391 .B C\-x c
392 run the
393 .\"LINK2"
394 Chmod
395 .\"Chmod"
396 command on a file or on the tagged files.
398 .B C\-x o
399 run the
400 .\"LINK2"
401 Chown
402 .\"Chown"
403 command on the current file or on the tagged files.
405 .B C\-x l
406 run the hard link command.
408 .B C\-x s
409 run the absolute symbolic link command.
411 .B C\-x v
412 run the relative symbolic link command. See the
413 .\"LINK2"
414 File Menu
415 .\"File Menu"
416 section for more information about symbolic links.
418 .B C\-x i
419 set the other panel display mode to information.
421 .B C\-x q
422 set the other panel display mode to quick view.
424 .B C\-x !
425 execute the
426 .\"LINK2"
427 External panelize
428 .\"External panelize"
429 command.
431 .B C\-x h
432 run the
433 .\"LINK2"
434 add directory to hotlist
435 .\"Hotlist"
436 command.
438 .B Alt\-!
439 executes the Filtered view command, described in the
440 .\"LINK2"
441 view command\&.
442 .\"Internal File Viewer"
444 .B Alt\-?
445 executes the
446 .\"LINK2"
447 Find file
448 .\"Find File"
449 command.
451 .B Alt\-c
452 pops up the
453 .\"LINK2"
454 quick cd
455 .\"Quick cd"
456 dialog.
458 .B C\-o
459 when the program is being run in the Linux or FreeBSD console or under
460 an xterm, it will show you the output of the previous command.  When ran
461 on the Linux console, the Midnight Commander uses an external program
462 (cons.saver) to handle saving and restoring of information on the
463 screen.
465 When the subshell support is compiled in, you can type C\-o at any time
466 and you will be taken back to the Midnight Commander main screen, to
467 return to your application just type C\-o.  If you have an application
468 suspended by using this trick, you won't be able to execute other
469 programs from the Midnight Commander until you terminate the suspended
470 application.
471 .\"NODE "  Directory Panels"
472 .SH "  Directory Panels"
473 This section lists the keys which operate on the directory panels. If
474 you want to know how to change the appearance of the panels take a
475 look at the section on
476 .\"LINK2"
477 Left and Right Menus\&.
478 .\"Left and Right Menus"
480 .B Tab, C\-i
481 change the current panel. The old other panel becomes the new current
482 panel and the old current panel becomes the new other panel. The
483 selection bar moves from the old current panel to the new current
484 panel.
486 .B Insert, C\-t
487 to tag files you may use the Insert key (the kich1 terminfo sequence).
488 To untag files, just retag a tagged file.
490 .B M\-e
491 to change charset of panel you may use M\-e (Alt\-e).
492 Recoding is made from selected codepage into system codepage. To
493 cancel the recoding you may select "directory up" (..) in active panel.
494 To cancel the charsets in all directories, select "No translation " in
495 the dialog of encodings.
497 .B Alt\-g, Alt\-r, Alt\-j
498 used to select the top file in a panel, the middle file and the bottom one,
499 respectively.
501 .B Alt\-t
502 toggle the current display listing to show the next display listing
503 mode.
504 With this it is possible to quickly switch to brief listing, long
505 listing, user defined listing mode, and back to the default.
507 .B C\-\\\\ (control\-backslash)
508 show the
509 .\"LINK2"
510 directory hotlist
511 .\"Hotlist"
512 and change to the selected directory.
514 .B + \ (plus)
515 this is used to select (tag) a group of files.  The Midnight Commander
516 will prompt for a selection options. When
517 .I Files only
518 checkbox is on, only files will be selected.  If
519 .I Files only
520 is off, as files as directories will be selected.
521 When
522 .I Shell Patterns
523 checkbox is on, the regular expression is much like the filename globbing
524 in the shell (* standing for zero or more characters and ? standing
525 for one character). If
526 .I Shell Patterns
527 is off, then the tagging of files is done with normal regular
528 expressions (see ed (1)). When
529 .I Case sensitive
530 checkbox is on, the selection will be case sensitive characters.
532 .I Case sensitive
533 is off, the case will be ignored.
535 .B \\\\ (backslash)
536 use the "\\" key to unselect a group of files. This is the opposite of
537 the Plus key.
539 .B up\-key, C\-p
540 move the selection bar to the previous entry in the panel.
542 .B down\-key, C\-n
543 move the selection bar to the next entry in the panel.
545 .B home, a1, Alt\-<
546 move the selection bar to the first entry in the panel.
548 .B end, c1, Alt\->
549 move the selection bar to the last entry in the panel.
551 .B next\-page, C\-v
552 move the selection bar one page down.
554 .B prev\-page, Alt\-v
555 move the selection bar one page up.
557 .B Alt\-o
558 If the currently selected file is a directory, load that directory on
559 the other panel and moves the selection to the next file. If the
560 currently selected file is not a directory, load the parent directory
561 on the other panel and moves the selection to the next file.
563 .B Alt\-i
564 make the current directory of the current panel also the current
565 directory of the other panel.  Put the other panel to the listing mode
566 if needed.  If the current panel is panelized, the other panel doesn't
567 become panelized.
569 .B C\-PageUp, C\-PageDown
570 only when supported by the terminal: change to ".." and to the currently
571 selected directory respectively.
573 .B Alt\-y
574 moves to the previous directory in the history, equivalent to clicking
576 .I <
577 with the mouse.
579 .B Alt\-u
580 moves to the next directory in the history, equivalent to clicking the
581 .I >
582 with the mouse.
584 .B Alt\-Shift\-h, Alt\-H
585 displays the directory history, equivalent to depressing the 'v' with
586 the mouse.
587 .\"NODE "  Quick search"
588 .SH "  Quick search"
589 The Quick search mode allows you to perform fast file search in file panel.
590 Press
591 .I C\-s
593 .I Alt\-s
594 to start a filename search in the directory listing.
596 When the search is active, the user input will be added to the search string
597 instead of the command line. If the
598 .I Show mini\-status
599 option is enabled the search string is shown on the mini\-status
600 line. When typing, the selection bar will move to the next file
601 starting with the typed letters. The
602 .I Backspace
604 .I DEL
605 keys can be used to correct typing mistakes. If C\-s is pressed
606 again, the next match is searched for.
608 If quick search is started with double pressing of C\-s, the previous quick
609 search pattern will be used for current search.
611 Besides the filename characters, you can also use wildcard
612 characters '*' and '?'.
613 .\"NODE "  Shell Command Line"
614 .SH "  Shell Command Line"
615 This section lists keys which are useful to avoid excessive typing when
616 entering shell commands.
618 .B Alt\-Enter
619 copy the currently selected file name to the command line.
621 .B C\-Enter
622 same a Alt\-Enter.  May not work on remote systems and some terminals.
624 .B C\-Shift\-Enter
625 copy the full path name of the currently selected file to the command
626 line.  May not work on remote systems and some terminals.
628 .B Alt\-Tab
629 does the filename, command, variable, username and hostname
630 .\"LINK2"
631 completion
632 .\"Completion"
633 for you.
635 .B C\-x t, C\-x C\-t
636 copy the tagged files (or if there are no tagged files, the selected
637 file) of the current panel (C\-x t) or of the other panel (C\-x C\-t) to
638 the command line.
640 .B C\-x p, C\-x C\-p
641 the first key sequence copies the current path name to the command
642 line, and the second one copies the unselected panel's path name to
643 the command line.
645 .B C\-q
646 the quote command can be used to insert characters that are otherwise
647 interpreted by the Midnight Commander (like the '+' symbol)
649 .B Alt\-p, Alt\-n
650 use these keys to browse through the command history. Alt\-p takes you
651 to the last entry, Alt\-n takes you to the next one.
653 .B Alt\-h
654 displays the history for the current input line.
655 .\"NODE "  General Movement Keys"
656 .SH "  General Movement Keys"
657 The help viewer, the file viewer and the directory tree use common
658 code to handle moving. Therefore they accept exactly the same
659 keys. Each of them also accepts some keys of its own.
661 Other parts of the Midnight Commander use some of the same movement
662 keys, so this section may be of use for those parts too.
664 .B Up, C\-p
665 moves one line backward.
667 .B Down, C\-n
668 moves one line forward.
670 .B Prev Page, Page Up, Alt\-v
671 moves one page up.
673 .B Next Page, Page Down, C\-v
674 moves one page down.
676 .B Home, A1
677 moves to the beginning.
679 .B End, C1
680 move to the end.
682 The help viewer and the file viewer accept the following keys in
683 addition the to ones mentioned above:
685 .B b, C\-b, C\-h, Backspace, Delete
686 moves one page up.
688 .B Space bar
689 moves one page down.
691 .B u, d
692 moves one half of a page up or down.
694 .B g, G
695 moves to the beginning or to the end.
696 .\"NODE "  Input Line Keys"
697 .SH "  Input Line Keys"
698 The input lines (they are used for the
699 .\"LINK2"
700 command line
701 .\"Shell Command Line"
702 and for the query dialogs in the program) accept these keys:
704 .B C\-a
705 puts the cursor at the beginning of line.
707 .B C\-e
708 puts the cursor at the end of the line.
710 .B C\-b, move\-left
711 move the cursor one position left.
713 .B C\-f, move\-right
714 move the cursor one position right.
716 .B Alt\-f
717 moves one word forward.
719 .B Alt\-b
720 moves one word backward.
722 .B C\-h, Backspace
723 delete the previous character.
725 .B C\-d, Delete
726 delete the character in the point (over the cursor).
728 .B C\-@
729 sets the mark for cutting.
731 .B C\-w
732 copies the text between the cursor and the mark to a kill buffer and
733 removes the text from the input line.
735 .B Alt\-w
736 copies the text between the cursor and the mark to a kill buffer.
738 .B C\-y
739 yanks back the contents of the kill buffer.
741 .B C\-k
742 kills the text from the cursor to the end of the line.
744 .B Alt\-p, Alt\-n
745 Use these keys to browse through the command history. Alt\-p takes you
746 to the last entry, Alt\-n takes you to the next one.
748 .B Alt\-C\-h, Alt\-Backspace
749 delete one word backward.
751 .B Alt\-Tab
752 does the filename, command, variable, username and hostname
753 .\"LINK2"
754 completion
755 .\"Completion"
756 for you.
757 .SH ""
758 .\"NODE "Menu Bar"
759 .SH "Menu Bar"
760 The menu bar pops up when you press F9 or click the mouse on the top
761 row of the screen. The menu bar has five menus: "Left", "File",
762 "Command", "Options" and "Right".
765 .\"LINK2"
766 Left and Right Menus
767 .\"Left and Right Menus"
768 allow you to modify the appearance of the left and right directory
769 panels.
772 .\"LINK2"
773 File Menu
774 .\"File Menu"
775 lists the actions you can perform on the currently selected file or
776 the tagged files.
779 .\"LINK2"
780 Command Menu
781 .\"Command Menu"
782 lists the actions which are more general and bear no relation to the
783 currently selected file or the tagged files.
786 .\"LINK2"
787 Options Menu
788 .\"Options Menu"
789 lists the actions which allow you to customize the Midnight Commander.
790 .\"NODE "  Left and Right Menus"
791 .SH "  Left and Right (Above and Below) Menus"
792 The outlook of the directory panels can be changed from the
793 .B Left
795 .B Right
796 menus (they are named
797 .B Above
799 .B Below
800 when the horizontal panel split is chosen from the
801 .\"LINK2"
802 Layout
803 .\"Layout"
804 options dialog).
805 .\"NODE "    Listing Mode..."
806 .SH "    Listing Mode..."
807 The listing mode view is used to display a listing of files, there are
808 four different listing modes available:
809 .BR Full ,
810 .BR Brief ,
811 .B Long
813 .BR User .
814 The full directory view shows the file name, the size of the file and
815 the modification time.
817 The brief view shows only the file name and it has two columns
818 (therefore showing twice as many files as other views). The long view
819 is similar to the output of
820 .B "ls \-l"
821 command. The long view takes the whole screen width.
823 If you choose the "User" display format, then you have to specify
824 the display format.
826 The user display format must start with a panel size specifier.  This
827 may be "half" or "full", and they specify a half screen panel and a
828 full screen panel respectively.
830 After the panel size, you may specify the two columns mode on the
831 panel, this is done by adding the number "2" to the user format
832 string.
834 After this you add the name of the fields with an optional size
835 specifier.  This are the available fields you may display:
837 .B name
838 displays the file name.
840 .B size
841 displays the file size.
843 .B bsize
844 is an alternative form of the
845 .B size
846 format. It displays the size of the files and for directories it just
847 shows SUB\-DIR or UP\-\-DIR.
849 .B type
850 displays a one character wide type field.  This character is similar to
851 what is displayed by ls with the \-F flag \-
852 .B *
853 for executable files,
854 .B /
855 for directories,
856 .B @
857 for links,
858 .B =
859 for sockets,
860 .B \-
861 for character devices,
862 .B +
863 for block devices,
864 .B |
865 for pipes,
866 .B ~
867 for symbolic links to directories and
868 .B !
869 for stale symlinks (links that point nowhere).
871 .B mark
872 an asterisk if the file is tagged, a space if it's not.
874 .B mtime
875 file's last modification time.
877 .B atime
878 file's last access time.
880 .B ctime
881 file's status change time.
883 .B perm
884 a string representing the current permission bits of the file.
886 .B mode
887 an octal value with the current permission bits of the file.
889 .B nlink
890 the number of links to the file.
892 .B ngid
893 the GID (numeric).
895 .B nuid
896 the UID (numeric).
898 .B owner
899 the owner of the file.
901 .B group
902 the group of the file.
904 .B inode
905 the inode of the file.
907 Also you can use following keywords to define the panel layout:
909 .B space
910 a space in the display format.
912 .B |
913 add a vertical line to the display format.
915 To force one field to a fixed size (a size specifier), you just add
916 .B :
917 followed by the number of characters you want the field to have.  If the
918 number is followed by the symbol
919 .BR + ,
920 then the size specifies the minimal field size \- if the program finds
921 out that there is more space on the screen, it will then expand that
922 field.
924 For example, the
925 .B Full
926 display corresponds to this format:
928 half type name | size | mtime
930 And the
931 .B Long
932 display corresponds to this format:
934 full perm space nlink space owner space group space size space mtime
935 space name
937 This is a nice user display format:
939 half name | size:7 | type mode:3
941 Panels may also be set to the following modes:
943 .B "Info"
944 The info view display information related to the currently
945 selected file and if possible information about the current file
946 system.
948 .B "Tree"
949 The tree view is quite similar to the
950 .\"LINK2"
951 directory tree
952 .\"Directory Tree"
953 feature. See the section about it for more information.
955 .B "Quick View"
956 In this mode, the panel will switch to a reduced
957 .\"LINK2"
958 viewer
959 .\"Internal File Viewer"
960 that displays the contents of the currently selected file, if you
961 select the panel (with the tab key or the mouse), you will have access
962 to the usual viewer commands.
963 .\"NODE "    Sort Order..."
964 .SH "    Sort Order..."
965 The eight sort orders are by name, by extension, by modification time,
966 by access time, and by inode information modification time, by size,
967 by inode and unsorted.  In the Sort order dialog box you can choose
968 the sort order and you may also specify if you want to sort in reverse
969 order by checking the reverse box.
971 By default directories are sorted before files but this can be changed
972 from the
973 .\"LINK2"
974 Panel options
975 .\"Panel options"
976 menu (option
977 .BR "Mix all files" ).
978 .\"NODE "    Filter..."
979 .SH "    Filter..."
980 The filter command allows you to specify a shell pattern (for example
981 .BR "*.tar.gz" )
982 which the files must match to be shown. Regardless
983 of the filter pattern, the directories and the links to directories
984 are always shown in the directory panel.
985 .\"NODE "    Reread"
986 .SH "    Reread"
987 The reread command reload the list of files in the directory. It is
988 useful if other processes have created or removed files.
989 .\"NODE "  File Menu"
990 .SH "  File Menu"
991 The Midnight Commander uses the F1 \- F10 keys as keyboard shortcuts
992 for commands appearing in the file menu.  The escape sequences for the
993 function keys are terminfo capabilities kf1 trough kf10.  On terminals
994 without function key support, you can achieve the same functionality by
995 pressing the ESC key and then a number in the range 1 through 9 and 0
996 (corresponding to F1 to F9 and F10 respectively).
998 The File menu has the following commands (keyboard shortcuts in parentheses):
1000 .B Help (F1)
1002 Invokes the built\-in hypertext help viewer. Inside the
1003 .\"LINK2"
1004 help viewer\&,
1005 .\"Contents"
1006 you can use the Tab key to select the next link and the Enter key to
1007 follow that link. The keys Space and Backspace are used to move
1008 forward and backward in a help page. Press F1 again to get the full
1009 list of accepted keys.
1011 .B Menu (F2)
1013 Invoke the
1014 .\"LINK2"
1015 user menu\&.
1016 .\"Menu File Edit"
1017 The user menu provides an easy way to provide users with a menu and
1018 add extra features to the Midnight Commander.
1020 .B View (F3, F13)
1022 View the currently selected file. By default this invokes the
1023 .\"LINK2"
1024 Internal File Viewer
1025 .\"Internal File Viewer"
1026 but if the option "Use internal view" is off, it invokes an external
1027 file viewer specified by the
1028 .B VIEWER
1029 environment variable.  If
1030 .B VIEWER
1031 is undefined, the
1032 .B PAGER
1033 environment variable is tried.  If
1034 .B PAGER
1035 is also undefined, the "view" command is invoked.  If you use F13
1036 instead, the viewer will be invoked without doing any formatting or
1037 preprocessing to the file.
1039 .B Filtered View (Alt\-!)
1041 This command prompts for a command
1042 and its arguments (the argument defaults to the currently selected
1043 file name), the output from such command is shown in the internal file
1044 viewer.
1046 .B Edit (F4, F14)
1048 Press F4 to edit the highlighted file.  Press F14 (usually F14)
1049 to start the editor with a new, empty file.
1050 Currently they invoke the
1051 .B vi
1052 editor, or the editor specified in the
1053 .B EDITOR
1054 environment variable, or the
1055 .\"LINK2"
1056 Internal File Editor
1057 .\"Internal File Editor"
1058 if the use_internal_edit option is on.
1060 .B Copy (F5, F15)
1062 Press F5 to pop up an input dialog to copy the currently selected file (or
1063 the tagged files, if there is at least one file tagged) to the
1064 directory/filename you specify in the input dialog. The destination
1065 defaults to the directory in the non\-selected panel. Space for destination
1066 file may be preallocated relative to preallocate_space configure option.
1067 During this process, you can press C\-c or ESC to abort the operation.
1068 For details about source mask (which will be usually either * or ^\\(.*\\)$
1069 depending on setting of Use shell patterns) and possible wildcards in the
1070 destination see
1071 .\"LINK2"
1072 Mask copy/rename\&.
1073 .\"Mask Copy/Rename"
1075 F15 (usually F15) is similar, but defaults to the directory in the
1076 selected panel. It always operates on the selected file, regardless of
1077 any tagged files.
1079 On some systems, it is possible to do the copy in the background by
1080 clicking on the background button (or pressing Alt\-b in the dialog
1081 box).  The
1082 .\"LINK2"
1083 Background Jobs
1084 .\"Background jobs"
1085 is used to control the background process.
1087 .B Link (C\-x l)
1089 Create a hard link to the current file.
1091 .B Absolute symlink (C\-x s)
1093 Create a absolute symbolic link to the current file.
1095 .B Relative symLink (C\-x v)
1097 Create a relative symbolic link to the current file.
1099 To those of you who don't know what links are: creating a link to a file
1100 is a bit like copying the file, but both the source filename and the destination
1101 filename represent the same file image. For example, if you edit one of these
1102 files, all changes you make will appear in both files. Some people call
1103 links aliases or shortcuts.
1105 A hard link appears as a real file. After making it, there is no way of
1106 telling which one is the original and which is the link. If you delete
1107 either one of them the other one is still intact. It is very difficult
1108 to notice that the files represent the same image. Use hard links when
1109 you don't even want to know.
1111 A symbolic link is a reference to the name of the original file. If
1112 the original file is deleted the symbolic link is useless. It is quite
1113 easy to notice that the files represent the same image. The Midnight
1114 Commander shows an "@"\-sign in front of the file name if it is a
1115 symbolic link to somewhere (except to directory, where it shows a tilde (~)).
1116 The original file which the link points to is shown on mini\-status line if the
1117 .I "Show mini\-status"
1118 option is enabled. Use symbolic links when you want to avoid the
1119 confusion that can be caused by hard links.
1121 When you press "C\-x s" Midnight Commander will automatically fill in the
1122 complete path+filename of the original file and suggest a name for the link.
1123 You can change either one.
1125 Sometimes you may want to change the absolute path of the original into
1126 a relative path. An absolute path starts from the root directory:
1128 .I /home/frodo/mc/mc -> /home/frodo/new/mc
1130 A relative link describes the original file's location starting from the
1131 location of the link itself:
1133 .I /home/frodo/mc/mc -> ../new/mc
1135 You can force Midnight Commander to suggest a relative path by pressing
1136 "C\-x v" instead of "C\-x s".
1138 .B Rename/Move (F6, F16)
1140 Press F6 to pop up an input dialog to copy the currently selected file (or
1141 the tagged files, if there is at least one file tagged) to the
1142 directory/filename you specify in the input dialog.  The destination
1143 defaults to the directory in the non\-selected panel. For more details
1144 look at Copy (F5) operation above, most of the things are quite similar.
1146 F16 (usually F16) is similar, but defaults to the directory in the
1147 selected panel. It always operates on the selected file, regardless of
1148 any tagged files.
1150 On some systems, it is possible to do the copy in the background by
1151 clicking on the background button (or pressing Alt\-b in the dialog
1152 box).  The
1153 .\"LINK2"
1154 Background Jobs
1155 .\"Background jobs"
1156 is used to control the background process.
1158 .B Mkdir (F7)
1160 Pop up an input dialog and creates the directory specified.
1162 .B Delete (F8)
1164 Delete the currently selected file or the tagged files in the
1165 currently selected panel. During the process, you can press C\-c or
1166 ESC to abort the operation.
1168 .B Quick cd (Alt\-c)
1169 Use the
1170 .\"LINK2"
1171 quick cd
1172 .\"Quick cd"
1173 command if you have full command line and want to cd somewhere.
1175 .B Select group (+)
1177 This is used to select (tag) a group of files. The Midnight Commander
1178 will prompt for a selection options. When
1179 .I Files only
1180 checkbox is on, only files will be selected.  If
1181 .I Files only
1182 is off, as files as directories will be selected.
1183 When
1184 .I Shell Patterns
1185 checkbox is on, the regular expression is much like the filename globbing
1186 in the shell (* standing for zero or more characters and ?  standing
1187 for one character). If
1188 .I Shell Patterns
1189 is off, then the tagging of files is done with normal regular
1190 expressions (see ed (1)). When
1191 .I Case sensitive
1192 checkbox is on, the selection will be case sensitive characters.
1194 .I Case sensitive
1195 is off, the case will be ignored.
1197 .B Unselect group (\\\\)
1199 Used to unselect a group of files. This is the opposite of the
1200 .I "Select group"
1201 command.
1203 .B Quit (F10, Shift\-F10)
1205 Terminate the Midnight Commander.  Shift\-F10 is used when you want to
1206 quit and you are using the shell wrapper.  Shift\-F10 will not take you
1207 to the last directory you visited with the Midnight Commander, instead
1208 it will stay at the directory where you started the Midnight Commander.
1209 .\"NODE "    Quick cd"
1210 .SH "    Quick cd"
1211 This command is useful if you have a full command line and want to
1212 .\"LINK2"
1214 .\"The cd internal command"
1215 somewhere without having to yank and paste the command line. This command
1216 pops up a small dialog, where you enter everything you would enter after
1217 .B cd
1218 on the command line and then you press enter. This features all the things
1219 that are already in the
1220 .\"LINK2"
1221 internal cd command\&.
1222 .\"The cd internal command"
1223 .\"NODE "  Command Menu"
1224 .SH "  Command Menu"
1226 .\"LINK2"
1227 Directory tree
1228 .\"Directory Tree"
1229 command shows a tree figure of the directories.
1232 .\"LINK2"
1233 "Find file"
1234 .\"Find File"
1235 command allows you to search for a specific file.
1237 The "Swap panels" command swaps the contents of the two directory panels.
1239 The "Switch panels on/off" command shows the output of the last shell command.
1240 This works only on xterm and on Linux and FreeBSD console.
1242 The "Compare directories" command compares the directory
1243 panels with each other. You can then use the Copy (F5) command to make
1244 the panels identical. There are three compare methods. The quick method
1245 compares only file size and file date. The thorough method makes a
1246 full byte\-by\-byte compare. The thorough method is not available if the
1247 machine does not support the mmap(2) system call.  The size\-only
1248 compare method just compares the file sizes and does not check the
1249 contents or the date times, it just checks the file size.
1252 .\"LINK2"
1253 "External panelize"
1254 .\"External panelize"
1255 allows you to execute an external program, and make the output of that
1256 program the contents of the current panel.
1258 The "Command history" command shows a list of typed commands. The
1259 selected command is copied to the command line. The command history
1260 can also be accessed by typing Alt\-p or Alt\-n.
1263 .\"LINK2"
1264 "Directory hotlist"
1265 .\"Hotlist"
1266 command makes changing of the current directory to often used directories
1267 faster.
1270 .\"LINK2"
1271 "Screen list"
1272 .\"Screen selector"
1273 command shows a dialog window with the list of currently running
1274 internal editors, viewers and other MC modules that support this mode.
1277 .\"LINK2"
1278 "Edit extension file"
1279 .\"Extension File Edit"
1280 command allows you to specify programs to executed when you try to
1281 execute, view, edit and do a bunch of other thing on files
1282 with certain extensions (filename endings).
1285 .\"LINK2"
1286 "Edit menu file"
1287 .\"Menu File Edit"
1288 command may be used for editing the user menu (which appears by
1289 pressing F2).
1290 .\"NODE "    Directory Tree"
1291 .SH "    Directory Tree"
1292 The Directory Tree command shows a tree figure of the directories. You
1293 can select a directory from the figure and the Midnight Commander will
1294 change to that directory.
1296 There are two ways to invoke the tree. The real directory tree command
1297 is available from Commands menu. The other way is to select tree view
1298 from the Left or Right menu.
1300 To get rid of long delays the Midnight Commander creates the tree
1301 figure by scanning only a small subset of all the directories. If the
1302 directory which you want to see is missing, move to its parent
1303 directory and press C\-r (or F2).
1305 You can use the following keys:
1307 .\"LINK2"
1308 General movement keys
1309 .\"General Movement Keys"
1310 are accepted.
1312 .B Enter.
1313 In the directory tree, exits the directory tree and changes to this
1314 directory in the current panel. In the tree view, changes to this
1315 directory in the other panel and stays in tree view mode in the
1316 current panel.
1318 .B C\-r, F2 (Rescan).
1319 Rescan this directory. Use this when the tree figure is out of date:
1320 it is missing subdirectories or shows some subdirectories which don't
1321 exist any more.
1323 .B F3 (Forget).
1324 Delete this directory from the tree figure. Use this to remove clutter
1325 from the figure. If you want the directory back to the tree figure
1326 press F2 in its parent directory.
1328 .B F4 (Static/Dynamic).
1329 Toggle between the dynamic navigation mode (default) and the static
1330 navigation mode.
1332 In the static navigation mode you can use the Up and Down keys to
1333 select a directory. All known directories are shown.
1335 In the dynamic navigation mode you can use the Up and Down keys to
1336 select a sibling directory, the Left key to move to the parent
1337 directory, and the Right key to move to a child directory. Only the
1338 parent, sibling and children directories are shown, others are left
1339 out. The tree figure changes dynamically as you traverse.
1341 .B F5 (Copy).
1342 Copy the directory.
1344 .B F6 (RenMov).
1345 Move the directory.
1347 .B F7 (Mkdir).
1348 Make a new directory below this directory.
1350 .B F8 (Delete).
1351 Delete this directory from the file system.
1353 .B C\-s, Alt\-s.
1354 Search the next directory matching the search string. If there is
1355 no such directory these keys will move one line down.
1357 .B C\-h, Backspace.
1358 Delete the last character of the search string.
1360 .B Any other character.
1361 Add the character to the search string and move to the next directory
1362 which starts with these characters. In the tree view you must first
1363 activate the search mode by pressing C\-s. The search string is shown
1364 in the mini status line.
1366 The following actions are available only in the directory tree. They
1367 aren't supported in the tree view.
1369 .B F1 (Help).
1370 Invoke the help viewer and show this section.
1372 .B Esc, F10.
1373 Exit the directory tree. Do not change the directory.
1375 The mouse is supported. A double\-click behaves like Enter. See
1376 also the section on
1377 .\"LINK2"
1378 mouse support\&.
1379 .\"Mouse Support"
1380 .\"NODE "    Find File"
1381 .SH "    Find File"
1382 The Find File feature first asks for the start directory for the
1383 search and the filename to be searched for. By pressing the Tree
1384 button you can select the start directory from the
1385 .\"LINK2"
1386 directory tree
1387 .\"Directory Tree"
1388 figure.
1390 Option \"Whole words\" allows select only those files containing matches that
1391 form whole words. Like grep \-w.
1393 You can start the search by pressing the OK button.
1394 During the search you can stop from the Stop button and continue from
1395 the Start button.
1397 You can browse the filelist with the up and down arrow keys. The Chdir
1398 button will change to the directory of the currently selected
1399 file. The Again button will ask for the parameters for a new
1400 search. The Quit button quits the search operation. The Panelize
1401 button will place the found files to the current directory panel so
1402 that you can do additional operations on them (view, copy, move,
1403 delete and so on). After panelizing you can press C\-r to return to the
1404 normal file listing.
1406 The 'Enable ignore directories' checkbox and input field below it
1407 allow to set up the list of directories that should be skip during the search
1408 files (for example, you may want to avoid searches on a CD\-ROM or on a NFS
1409 directory that is mounted across a slow link). List components must be separated
1410 with a colon, here is an example:
1413 /cdrom:/nfs/wuarchive:/afs
1416 Relative paths are supported also. The following example shows how to skip special
1417 directories of version control systems:
1419 /cdrom:/nfs/wuarchive:/afs:.svn:.git:CVS
1422 Attention: input field can contain a dot (.), this means the current absolute path.
1424 You may consider using the
1425 .\"LINK2"
1426 External panelize
1427 .\"External panelize"
1428 command for some operations. Find file command is for simple queries
1429 only, while using External panelize you can do as mysterious searches
1430 as you would like.
1431 .\"NODE "    External panelize"
1432 .SH "    External panelize"
1433 The External panelize allows you to execute an external program, and
1434 make the output of that program the contents of the current panel.
1436 For example, if you want to manipulate in one of the panels all the
1437 symbolic links in the current directory, you can use external
1438 panelization to run the following command:
1441 find . \-type l \-print
1444 Upon command completion, the directory contents of the panel will no
1445 longer be the directory listing of the current directory, but all the
1446 files that are symbolic links.
1448 If you want to panelize all of the files that have been downloaded
1449 from your FTP server, you can use this awk command to extract the file
1450 name from the transfer log files:
1453 awk '$9 ~! /incoming/ { print $9 }' < /var/log/xferlog
1456 You may want to save often used panelize commands under a descriptive name,
1457 so that you can recall them quickly. You do this by typing the command on
1458 the input line and pressing Add new button. Then you enter a name under
1459 which you want the command to be saved. Next time, you just choose that
1460 command from the list and do not have to type it again.
1461 .\"NODE "    Hotlist"
1462 .SH "    Hotlist"
1463 The Directory hotlist command shows the labels of the directories
1464 in the directory hotlist.  The Midnight Commander will change to the
1465 directory corresponding to the selected label.  From the hotlist dialog,
1466 you can remove already created label/directory pairs and add new ones.
1467 To add new directories quickly, you can use the Add to hotlist command
1468 (C\-x h), which adds the current directory into the directory hotlist,
1469 asking just for the label for the directory.
1471 This makes cd to often used directories faster. You may consider using the
1472 CDPATH variable as described in
1473 .\"LINK2"
1474 internal cd command
1475 .\"The cd internal command"
1476 description.
1477 .\"NODE "    Extension File Edit"
1478 .SH "    Extension File Edit"
1479 This will invoke your editor on the file
1480 .IR ~/.config/mc/mc.ext .
1481 The format of this file following:
1483 All lines starting with # or empty lines are thrown away.
1485 Lines starting in the first column should have following format:
1487 .IR keyword/expr ,
1488 i.e. everything after the slash until new line is
1489 .IR expr .
1491 .I keyword
1492 can be:
1494 .I shell
1496 .I expr
1497 is an extension (no wildcards).  File matches it its name ends
1498 with
1499 .IR expr .
1500 Example:
1501 .I shell/.tar
1502 matches
1503 .IR *.tar .
1505 .I regex
1507 .I expr
1508 is a regular expression.  File matches if its name matches the regular
1509 expression.
1511 .I directory
1513 .I expr
1514 is a regular expression.  File matches if it is a directory and its name
1515 matches the regular expression.
1517 .I type
1519 .I expr
1520 is a regular expression.  File matches if the output of
1521 .I file %f
1522 without the initial "filename:" part matches regular expression
1523 .IR expr .
1525 .I default
1526 \- matches any file.
1527 .I expr
1528 is ignored.
1530 .I include
1531 \- denotes a common section.
1532 .I expr
1533 is the name of the section.
1535 Other lines should start with a space or tab and should be of the format:
1536 .I keyword=command
1537 (with no spaces around =), where
1538 .I keyword
1539 should be:
1540 .I Open
1541 (invoked on Enter or double click),
1542 .I View
1543 (F3),
1544 .I Edit
1545 (F4) or
1546 .I Include
1547 (to add rules from the common section).
1548 .I command
1549 is any one\-line shell command, with the simple
1550 .\"LINK2"
1551 macro substitution\&.
1552 .\"Macro Substitution"
1554 Rules are matched from top to bottom, thus the order is important.  If
1555 the appropriate action is missing, search continues as if this rule
1556 didn't match (i.e. if a file matches the first and second entry and View
1557 action is missing in the first one, then on pressing F3 the View action
1558 from the second entry will be used).
1559 .I default
1560 should match all the actions.
1561 .\"NODE "    Background jobs"
1562 .SH "    Background Jobs"
1563 This lets you control the state of any background Midnight Commander
1564 process (only copy and move files operations can be done in the
1565 background).  You can stop, restart and kill a background job from
1566 here.
1567 .\"NODE "    Menu File Edit"
1568 .SH "    Menu File Edit"
1569 The user menu is a menu of useful actions that can be customized by
1570 the user. When you access the user menu, the
1571 file .mc.menu from the current directory is used if it exists,
1572 but only if it is owned by user or root and is not world\-writable.
1573 If no such file found, ~/.config/mc/menu is tried in the same way,
1574 and otherwise mc uses the default system\-wide menu
1575 %prefix%/share/mc/mc.menu.
1577 The format of the menu file is very simple. Lines that start with
1578 anything but space or tab are considered entries for the menu (in
1579 order to be able to use it like a hot key, the first character should
1580 be a letter). All the lines that start with a space or a tab are the
1581 commands that will be executed when the entry is selected.
1583 When an option is selected all the command lines of the option are
1584 copied to a temporary file in the temporary directory (usually
1585 /usr/tmp) and then that file is executed. This allows the user to put
1586 normal shell constructs in the menus. Also simple macro substitution
1587 takes place before executing the menu code. For more information, see
1588 .\"LINK2"
1589 macro substitution\&.
1590 .\"Macro Substitution"
1592 Here is a sample mc.menu file:
1595 A       Dump the currently selected file
1596         od \-c %f
1598 B       Edit a bug report and send it to root
1599         I=`mktemp ${MC_TMPDIR:\-/tmp}/mail.XXXXXX` || exit 1
1600         vi $I
1601         mail \-s "Midnight Commander bug" root < $I
1602         rm \-f $I
1604 M       Read mail
1605         emacs \-f rmail
1607 N       Read Usenet news
1608         emacs \-f gnus
1610 H       Call the info hypertext browser
1611         info
1613 J       Copy current directory to other panel recursively
1614         tar cf \- . | (cd %D && tar xvpf \-)
1616 K       Make a release of the current subdirectory
1617         echo \-n "Name of distribution file: "
1618         read tar
1619         ln \-s %d `dirname %d`/$tar
1620         cd ..
1621         tar cvhf ${tar}.tar $tar
1623 = f *.tar.gz | f *.tgz & t n
1624 X       Extract the contents of a compressed tar file
1625         tar xzvf %f
1628 .B Default Conditions
1630 Each menu entry may be preceded by a condition. The condition must
1631 start from the first column with a '=' character. If the condition is
1632 true, the menu entry will be the default entry.
1635 Condition syntax:       = <sub\-cond>
1636   or:                   = <sub\-cond> | <sub\-cond> ...
1637   or:                   = <sub\-cond> & <sub\-cond> ...
1639 Sub\-condition is one of following:
1641   y <pattern>           syntax of current file matching pattern?
1642                         (for edit menu only)
1643   f <pattern>           current file matching pattern?
1644   F <pattern>           other file matching pattern?
1645   d <pattern>           current directory matching pattern?
1646   D <pattern>           other directory matching pattern?
1647   t <type>              current file of type?
1648   T <type>              other file of type?
1649   x <filename>          is it executable filename?
1650   ! <sub\-cond>         negate the result of sub\-condition
1653 Pattern is a normal shell pattern or a regular expression, according
1654 to the shell patterns option. You can override the global value of
1655 the shell patterns option by writing "shell_patterns=x" on the first
1656 line of the menu file (where "x" is either 0 or 1).
1658 Type is one or more of the following characters:
1661   n     not a directory
1662   r     regular file
1663   d     directory
1664   l     link
1665   c     character device
1666   b     block device
1667   f     FIFO (pipe)
1668   s     socket
1669   x     executable file
1670   t     tagged
1673 For example 'rlf' means either regular file, link or fifo. The 't'
1674 type is a little special because it acts on the panel instead of the
1675 file. The condition '=t t' is true if there are tagged files in the
1676 current panel and false if not.
1678 If the condition starts with '=?' instead of '=' a debug trace will be
1679 shown whenever the value of the condition is calculated.
1681 The conditions are calculated from left to right. This means
1683         = f *.tar.gz | f *.tgz & t n
1685 is calculated as
1687         ( (f *.tar.gz) | (f *.tgz) ) & (t n)
1690 Here is a sample of the use of conditions:
1693 = f *.tar.gz | f *.tgz & t n
1694 L       List the contents of a compressed tar\-archive
1695         gzip \-cd %f | tar xvf \-
1698 .B Addition Conditions
1700 If the condition begins with '+' (or '+?') instead of '=' (or '=?') it
1701 is an addition condition. If the condition is true the menu entry will
1702 be included in the menu. If the condition is false the menu entry will
1703 not be included in the menu.
1705 You can combine default and addition conditions by starting condition
1706 with '+=' or '=+' (or '+=?' or '=+?' if you want debug trace). If you
1707 want to use two different conditions, one for adding and another for
1708 defaulting, you can precede a menu entry with two condition lines, one
1709 starting with '+' and another starting with '='.
1711 Comments are started with '#'. The additional comment lines must start
1712 with '#', space or tab.
1713 .\"NODE "  Options Menu"
1714 .SH "  Options Menu"
1715 The Midnight Commander has some options that may be toggled on and
1716 off in several dialogs which are accessible from this menu. Options
1717 are enabled if they have an asterisk or "x" in front of them.
1720 .\"LINK2"
1721 Configuration
1722 .\"Configuration"
1723 command pops up a dialog from which you can change most of settings of
1724 the Midnight Commander.
1727 .\"LINK2"
1728 Layout
1729 .\"Layout"
1730 command pops up a dialog from which you specify a bunch of options how mc
1731 looks like on the screen.
1734 .\"LINK2"
1735 Panel options
1736 .\"Panel options"
1737 command pops up a dialog from which you specify options of file manager panels.
1740 .\"LINK2"
1741 Confirmation
1742 .\"Confirmation"
1743 command pops up a dialog from which you specify which actions you want to
1744 confirm.
1747 .\"LINK2"
1748 Display bits
1749 .\"Display bits"
1750 command pops up a dialog from which you may select which characters is your
1751 terminal able to display.
1754 .\"LINK2"
1755 Learn keys
1756 .\"Learn keys"
1757 command pops up a dialog from which you test some keys which are not working
1758 on some terminals and you may fix them.
1761 .\"LINK2"
1762 Virtual FS
1763 .\"Virtual FS"
1764 command pops up a dialog from which you specify some VFS related options.
1767 .\"LINK2"
1768 Save setup
1769 .\"Save Setup"
1770 command saves the current settings of the Left, Right and Options
1771 menus. A small number of other settings is saved, too.
1772 .\"NODE "    Configuration"
1773 .SH "    Configuration"
1774 The options in this dialog are divided into several groups: "File
1775 operation options", "Esc key mode", "Pause after run" and "Other options".
1777 .B File operation options
1779 .I Verbose operation.
1780 This toggles whether the file Copy, Rename and Delete operations are
1781 verbose (i.e., display a dialog box for each operation). If you have a
1782 slow terminal, you may wish to disable the verbose operation. It is
1783 automatically turned off if the speed of your terminal is less than
1784 9600 bps.
1786 .I Compute totals.
1787 If this option is enabled, the Midnight Commander computes total byte
1788 sizes and total number of files prior to any Copy, Rename and Delete
1789 operations. This will provide you with a more accurate progress bar
1790 at the expense of some speed. This option has no effect, if
1791 .I Verbose  operation
1792 is disabled.
1794 .I Classic progressbar.
1795 If this option is enabled, the progressbar of Copy/Move/Delete operations
1796 is always grown form left to right. If disabled, the growing direction
1797 of progressbar follows to direction of Copy/Move/Delete operation:
1798 from left panel to right one and vice versa. Enabled by default.
1800 .I Mkdir autoname
1801 When you press F7 to create a new directory, the input line in popup dialog
1802 will be filled by name of current file or directory in active panel.
1803 Disabled by default.
1805 .I Preallocate space
1806 Preallocate space for whole target file, if possible, before copy operation.
1807 Disabled by default.
1809 .B Esc key mode.
1811 By default the Midnight Commander treats the ESC key as a key prefix.
1812 Therefore, you should press Esc code twice to exit a dialog. But there is
1813 a possibility to use a single press of ESC key for that action.
1815 .I Single press.
1816 By default this option is disabled. If you'll enable it, the ESC key
1817 will act as a prefix key for set up time interval (see
1818 .I Timeout
1819 option below), and if no extra keys have arrived, then the ESC key
1820 is interpreted as a cancel key (ESC ESC).
1822 .I Timeout.
1823 This options is used to setup the time interval (in microseconds)
1824 for single press of ESC key. By default, this inrerval is one second
1825 (1000000 microseconds). Also the timeout can be set via KEYBOARD_KEY_TIMEOUT_US
1826 environment variable (also in microseconds), which has higher priority
1827 than Timeout option value.
1829 .B Pause after run
1831 After executing your commands, the Midnight Commander can pause, so
1832 that you can examine the output of the command.  There are three
1833 possible settings for this variable:
1835 .IR Never .
1836 Means that you do not want to see the output of your command.  If you
1837 are using the Linux or FreeBSD console or an xterm, you will be able to
1838 see the output of the command by typing C\-o.
1840 .IR On dumb terminals .
1841 You will get the pause message on terminals that are not capable of
1842 showing the output of the last command executed (any terminal that is
1843 not an xterm or the Linux console).
1845 .IR Always .
1846 The program will pause after executing all of your commands.
1848 .B Other options
1850 .I Use internal editor.
1851 If this option is enabled, the built\-in file editor is used to edit
1852 files. If the option is disabled, the editor specified in the
1853 .B EDITOR
1854 environment variable is used.
1855 If no editor is specified,
1856 .B vi
1857 is used.  See the section on the
1858 .\"LINK2"
1859 internal file editor\&.
1860 .\"Internal File Editor"
1862 .I Use internal viewer.
1863 If this option is enabled, the built\-in file viewer is used to view
1864 files. If the option is disabled, the pager specified in the
1865 .B PAGER
1866 environment variable is used.
1867 If no pager is specified, the
1868 .B view
1869 command is used.  See the section on the
1870 .\"LINK2"
1871 internal file viewer\&.
1872 .\"Internal File Viewer"
1874 .I Auto menus.
1875 If this option is enabled, the user menu will be invoked at startup.
1876 Useful for building menus for non\-unixers.
1878 .I Drop down menus.
1879 When this option is enabled, the pull down menus will be activated as
1880 soon as you press the F9 key. Otherwise, you will only get the menu title,
1881 and you will have to activate the menu either with the arrow keys or with
1882 the hotkeys. It is recommended if you are using hotkeys.
1884 .I Shell Patterns.
1885 By default the Select, Unselect and Filter commands will use shell\-like
1886 regular expressions. The following conversions are performed to achieve
1887 this: the '*' is replaced by '.*' (zero or more characters); the '?'
1888 is replaced by '.' (exactly one character) and '.' by the literal
1889 dot. If the option is disabled, then the regular expressions are the
1890 ones described in ed(1).
1892 .I Complete: show all.
1893 By default the Midnight Commander pops up all possible
1894 .\"LINK2"
1895 completions
1896 .\"Completion"
1897 if the completion is ambiguous only when you press
1898 .B Alt\-Tab
1899 for the second time.  For the first time, it just completes as much as
1900 possible and beeps in the case of ambiguity.  Enable this option if you
1901 want to see all possible completions even after pressing
1902 .B Alt\-Tab
1903 the first time.
1905 .I Rotating dash.
1906 If this option is enabled, the
1907 Midnight Commander shows a rotating dash in the upper right corner
1908 as a work in progress indicator.
1910 .I Cd follows links.
1911 This option, if set, causes the Midnight Commander to follow the
1912 logical chain of directories when changing current directory
1913 either in the panels, or using the cd command. This is the default
1914 behavior of bash. When unset, the Midnight Commander follows the
1915 real directory structure, so cd .. if you've entered that directory
1916 through a link will move you to the current directory's real parent
1917 and not to the directory where the link was present.
1919 .I Safe delete.
1920 If this option is enabled, deleting files and directory hotlist entries
1921 unintentionally becomes more difficult.  The default selection in the
1922 confirmation dialogs for deletion changes from "Yes" to "No".
1923 This option is disabled by default.
1925 .I Auto save setup.
1926 If this option is enabled, when you exit the Midnight Commander the
1927 configurable options of the Midnight Commander are saved in the
1928 ~/.config/mc/ini file.
1929 .\"NODE "    Layout"
1930 .SH "    Layout"
1931 The layout dialog gives you a possibility to change the general layout
1932 of screen. The options in this dialog are divided into several groups:
1933 "Panel split", "Console output" and "Other options".
1935 .B Panel split
1937 The rest of the screen area is used for the two directory panels. You
1938 can specify whether the area is split to the panels in
1939 .I Vertical
1940  or
1941 .I Horizontal
1942 direction. Panel layout can be changed using Alt\-, (Alt\-comma) shortcut.
1944 .I Equal split.
1945 By default, panels have equal sizes. Using this option you can specify
1946 an unequal split.
1948 .B Console output
1950 On the Linux or FreeBSD console you can specify how many lines are shown
1951 in the output window. This option is available if Midnight Commander runs
1952 on native console only.
1954 .B Other options
1956 .I Menu bar visible.
1957 If enabled, main menu of Midnight Commander is always visible on the top row
1958 of screen above panels. Enabled by default.
1960 .I Command prompt.
1961 If enabled, command line is avalable. Enabled by default.
1963 .I Keybar visible.
1964 If enabled, 10 lables associated with F1\-F10 keys are located at the bottom
1965 row of screen. Enabled by default.
1967 .I Hintbar visible.
1968 If enabled, the one\-line hints are visible below panels. Enabled by default.
1970 .I XTerm window title.
1971 When run in a terminal emulator for X11, Midnight Commander sets the
1972 terminal window title to the current working directory and updates it
1973 when necessary.  If your terminal emulator is broken and you see some
1974 incorrect output on startup and directory change, turn off this option.
1975 Enabled by default.
1977 .I Show free space.
1978 If enabled, free space and total space of current file system is shown
1979 at the bottom frame of panel. Enabled by default.
1980 .\"NODE "    Panel options"
1981 .SH "    Panel options"
1982 .B Main panel options
1984 .I Show mini\-status.
1985 If enabled, one line of status information about the currently selected item
1986 is shown at the bottom of the panels. Enabled by default.
1988 .I Use SI size units.
1989 If this option is enabled, Midnight Commander will use SI units (powers of 1000)
1990 when displaying any byte sizes. The suffixes (k, m ...) are shown in lowercase.
1991 If disabled (default), Midnight Commander will use binary units (powers of 1024)
1992 and the suffixes are shown in upper case (K, M ...)
1994 .I Mix all files.
1995 If this option is enabled, all files and directories are shown mixed
1996 together.  If the option is desabled (default), directories (and links to
1997 directories) are shown at the beginning of the listing, and other files below.
1999 .I Show backup files.
2000 If enabled, the Midnight Commander will show files ending with a tilde.
2001 Otherwise, they won't be shown (like GNU's ls option \-B). Enabled by default.
2003 .I Show hidden files.
2004 If enabled, the Midnight Commander will show all files that start with
2005 a dot (like ls \-a). Disabled by default.
2007 .I Fast directory reload.
2008 If this option is enabled, the Midnight Commander will use a trick to
2009 determine if the directory contents have changed.  The trick is to reload
2010 the directory only if the i\-node of the directory has changed; this means
2011 that reloads only happen when files are created or deleted.  If what
2012 changes is the i\-node for a file in the directory (file size changes,
2013 mode or owner changes, etc) the display is not updated.  In these cases,
2014 if you have the option on, you have to rescan the directory manually
2015 (with C\-r). Disabled by default.
2017 .I Mark moves down.
2018 If enabled, the selection bar will move down when you mark a file (with
2019 Insert key). Enabled by default.
2021 .I Reverse files only.
2022 Allow revert selection of files only. Enabled by default.
2023 If enabled, the reverse selection is applied to files only, not to directories.
2024 The selection of directories is untouched. If off, the reverse selection
2025 is applied to files as well to directories: all unselected items become
2026 selected, and vice versa.
2028 .I Simple swap.
2029 If both panels contain file listing, simple swap means that panels exchange
2030 its screen positions: left panel become right one, and vice versa. If this
2031 option is unchecked, file listing panels exchange its content keeping listing
2032 format and sort options. Unchecked by default.
2034 .I Auto save panels setup.
2035 If this option is enabled, when you exit the Midnight Commander the
2036 current settings of panels are saved in the ~/.config/mc/panels.ini file.
2037 Disabled by default.
2039 .B Navigation
2041 .I Lynx\-like motion.
2042 If this option is enabled, you may use the arrows keys to automatically
2043 chdir if the current selection is a subdirectory and the shell command
2044 line is empty. By default, this setting is off.
2046 .I Page scrolling.
2047 If set (the default), panel will scroll by half the display when the
2048 cursor reaches the end or the beginning of the panel, otherwise it
2049 will just scroll a file at a time.
2051 .I Mouse page scrolling.
2052 Controls whenever scrolling with the mouse wheel is done by pages or
2053 line by line on the panels.
2055 .B File highlight
2057 You can specify whether
2058 .I permissions
2060 .I file types
2061 should be highlighted with distinctive
2062 .\"LINK2"
2063 Colors\&.
2064 .\"Colors"
2065 If the permission highlighting is enabled, the parts of the
2066 .I perm
2068 .I mode
2069 .\"LINK2"
2070 display fields
2071 .\"Listing Mode..."
2072 which apply to the user running Midnight Commander are highlighted with
2073 the color defined by the
2074 .I selected
2075 keyword.  If the file type highlighting is enabled, file names are colored
2076 according to rules described in
2077 %sysconfdir%/mc/filehighlight.ini
2078 file. See
2079 .\"LINK2"
2080 Filenames Highlight
2081 .\"Filenames Highlight"
2082 for more info.
2084 .B Quick search
2086 You can specify how the
2087 .\"LINK2"
2088 Quick search
2089 .\"Quick search"
2090 mode should works: case insensitively, case sensitively or be matched
2091 to the the panel sort order: case sensitive or not.
2092 .\"NODE "    Confirmation"
2093 .SH "    Confirmation"
2094 In this dialog you configure the confirmation options for file deletion,
2095 overwriting files, execution by pressing enter, quitting the program,
2096 directory hotlist entries deletion and history cleanup.
2097  and.
2098 .\"NODE "    Display bits"
2099 .SH "    Display bits"
2100 This is used to configure the range of visible characters on the
2101 screen.  This setting may be 7\-bits if your terminal/curses supports
2102 only seven output bits, ISO\-8859\-1 displays all the characters in the
2103 ISO\-8859\-1 map and full 8 bits is for those terminals that can display
2104 full 8 bit characters.
2105 .\"NODE "    Learn keys"
2106 .SH "    Learn keys"
2107 This dialog allows you to test and redefine functional keys, cursor
2108 arrows and some other keys to make them work properly on your terminal.
2109 They often don't, since many terminal databases are incomplete or broken.
2111 You can move around with the Tab key and with the vi moving keys ('h'
2112 left, 'j' down, 'k' up and 'l' right).  Once you press any cursor movement
2113 key and it is recognized, you can use that key as well.
2115 You can test keys just by pressing each of them.  When you press a
2116 key and it is recognized properly, OK should appear next to the name
2117 of that key.  Once a key is marked OK it starts working as usually,
2118 e.g. F1 pressed the first time will just check that the F1 key works,
2119 but after that it will show help.  The same applies to the arrow keys.
2120 The Tab key should be working always.
2122 If some keys do not work properly then you won't see OK appear after
2123 pressing one of these.  Then you may want to redefine it.  Do it by pressing
2124 the button with the name of that key (either by the mouse or by Enter
2125 or Space after selecting the button with Tab or arrows).  Then a message
2126 box will appear asking you to press that key.  Do it and wait until the
2127 message box disappears.  If you want to abort, just press Escape once
2128 and wait.
2130 When you finish with all the keys, you can Save them.  The definitions
2131 for the keys you have redefined will be written into the [terminal:TERM]
2132 section of your ~/.config/mc/ini file (where TERM is the name of your current
2133 terminal).  The definitions of the keys that were already working properly
2134 are not saved.
2135 .\"NODE "    Virtual FS"
2136 .SH "    Virtual FS"
2137 This option gives you control over the settings of the
2138 .\"LINK2"
2139 Virtual File System\&.
2140 .\"Virtual File System"
2142 The Midnight Commander keeps in memory the information related to some
2143 of the virtual file systems to speed up the access to the files in the
2144 file system (for example, directory listings fetched from FTP servers).
2146 Also, in order to access the contents of compressed files (for example,
2147 compressed tar files) the Midnight Commander needs to create temporary
2148 uncompressed files on your disk.
2150 Since both the information in memory and the temporary files on disk
2151 take up resources, you may want to tune the parameters of the cached
2152 information to decrease your resource usage or to maximize the speed of
2153 access to frequently used file systems.
2155 Because of the format of the tar archives, the
2156 .I Tar filesystem
2157 needs to read the whole file just to load the file entries.  Since most
2158 tar files are usually kept compressed (plain tar files are species in
2159 extinction), the tar file system has to uncompress the file on the disk
2160 in a temporary location and then access the uncompressed file as a
2161 regular tar file.
2163 Now, since we all love to browse files and tar files all over the disk,
2164 it's common that you will leave a tar file and then re\-enter it later.
2165 Since decompression is slow, the Midnight Commander will cache the
2166 information in memory for a limited time.  When the timeout expires, all
2167 the resources associated with the file system are released.  The default
2168 timeout is set to one minute.
2171 .\"LINK2"
2172 FTP File System
2173 .\"FTP File System"
2174 (ftpfs) allows you to browse directories on remote FTP servers.  It has
2175 several options.
2177 .I ftp anonymous password
2178 is the password used when you login as "anonymous".  Some sites require
2179 a valid e\-mail address.  On the other hand, you probably don't want to
2180 give your real e\-mail address to untrusted sites, especially if you are
2181 not using spam filtering.
2183 ftpfs keeps the directory listing it fetches from a FTP server in a cache.
2184 The cache expire time is configurable with the
2185 .I ftpfs directory cache timeout
2186 option.  A low value for this option may slow down every operation on
2187 the ftpfs because every operation would require sending a request to the
2188 FTP server.
2190 You can define an FTP proxy host for doing FTP.  Note that most modern
2191 firewalls are fully transparent at least for passive FTP (see below), so
2192 FTP proxies are considered obsolete.
2195 .I Always use ftp proxy
2196 is not set, you can use the exclamation sign to enable proxy for certain
2197 hosts.  See
2198 .\"LINK2"
2199 FTP File System
2200 .\"FTP File System"
2201 for examples.
2203 If this option is set, the program will do two things: consult the
2204 %prefix%/lib/mc/mc.no_proxy file for lines containing host names that
2205 are local (if the host name starts with a dot, it is assumed to be a
2206 domain) and to assume that any hostnames without dots in their names are
2207 directly accessible.  All other hosts will be accessed through the
2208 specified FTP proxy.
2210 You can enable using
2211 .I ~/.netrc
2212 file, which keeps login names and passwords for ftp servers.  See netrc
2213 (5) for the description of the .netrc format.
2215 .I Use passive mode
2216 enables using FTP passive mode, when the connection for data transfer is
2217 initiated by the client, not by the server.  This option is recommended
2218 and enabled by default.  If this option is turned off, the data
2219 connection is initiated by the server.  This may not work with some
2220 firewalls.
2221 .\"NODE "    Save Setup"
2222 .SH "    Save Setup"
2223 At startup the Midnight Commander will try to load initialization
2224 information from the ~/.config/mc/ini file. If this file
2225 doesn't exist, it will load the information from the system\-wide
2226 configuration file, located in %prefix%/share/mc/mc.ini. If the 
2227 system\-wide configuration file doesn't exist, MC uses the default settings.
2230 .I Save Setup
2231 command creates the ~/.config/mc/ini file by saving the
2232 current settings of the
2233 .\"LINK2"
2234 Left, Right
2235 .\"Left and Right Menus"
2237 .\"LINK2"
2238 Options
2239 .\"Options Menu"
2240 menus.
2242 If you activate the
2243 .I auto save setup
2244 option, MC will always save the current settings when exiting.
2246 There also exist settings which can't be changed from the menus. To
2247 change these settings you have to edit the setup file with your
2248 favorite editor. See the section on
2249 .\"LINK2"
2250 Special Settings
2251 .\"Special Settings"
2252 for more information.
2253 .SH ""
2254 .\"NODE "Executing operating system commands"
2255 .SH "Executing operating system commands"
2256 You may execute commands by typing them directly in the Midnight
2257 Commander's input line, or by selecting the program you want to
2258 execute with the selection bar in one of the panels and hitting Enter.
2260 If you press Enter over a file that is not executable, the Midnight
2261 Commander checks the extension of the selected file against the
2262 extensions in the
2263 .\"LINK2"
2264 Extensions File\&.
2265 .\"Extension File Edit"
2266 If a match is found then the code associated with that extension is
2267 executed. A very simple
2268 .\"LINK2"
2269 macro expansion
2270 .\"Macro Substitution"
2271 takes place before executing the command.
2272 .\"NODE "  The cd internal command"
2273 .SH "  The cd internal command"
2275 .I cd
2276 command is interpreted by the Midnight Commander, it is not passed to
2277 the command shell for execution.  Thus it may not handle all of the
2278 nice macro expansion and substitution that your shell does, although it
2279 does some of them:
2281 .I Tilde substitution.
2282 The (~) will be substituted with your home directory, if you append a
2283 username after the tilde, then it will be substituted with the login
2284 directory of the specified user.
2286 For example, ~guest is the home directory for the user guest, while
2287 ~/guest is the directory guest in your home directory.
2289 .I Previous directory.
2290 You can jump to the directory you were previously by using the special
2291 directory name '\-' like this:
2292 .B cd \-
2294 .I CDPATH directories.
2295 If the directory specified to the
2296 .B cd
2297 command is not in the current directory, then The Midnight Commander
2298 uses the value in the environment variable
2299 .B CDPATH
2300 to search for the directory in any of the named directories.
2302 For example you could set your
2303 .B CDPATH
2304 variable to ~/src:/usr/src, allowing you to change your directory to
2305 any of the directories inside the ~/src and /usr/src directories, from
2306 any place in the file system by using its relative name (for example
2307 cd linux could take you to /usr/src/linux).
2308 .\"NODE "  Macro Substitution"
2309 .SH "  Macro Substitution"
2310 When accessing a
2311 .\"LINK2"
2312 user menu\&,
2313 .\"Menu File Edit"
2314 or executing an
2315 .\"LINK2"
2316 extension dependent command\&,
2317 .\"Extension File Edit"
2318 or running a command from the command line input, a simple macro
2319 substitution takes place.
2321 The macros are:
2323 .I %i
2324 The indent of blank space, equal the cursor column position.  For edit
2325 menu only.
2327 .I %y
2328 The syntax type of current file. For edit menu only.
2330 .I %k
2331 The block file name.
2333 .I %e
2334 The error file name.
2336 .I %m
2337 The current menu name.
2339 .IR %f " and " %p
2340 The current file name.
2342 .I %x
2343 The extension of current file name.
2345 .I %b
2346 The current file name without extension.
2348 .I %d
2349 The current directory name.
2351 .I %F
2352 The current file in the unselected panel.
2354 .I %D
2355 The directory name of the unselected panel.
2357 .I %t
2358 The currently tagged files.
2360 .I %T
2361 The tagged files in the unselected panel.
2363 .IR %u " and " %U
2364 Similar to the %t and %T macros, but in addition the files are untagged.
2365 You can use this macro only once per menu file entry or extension file
2366 entry, because next time there will be no tagged files.
2368 .IR %s " and " %S
2369 The selected files: The tagged files if there are any. Otherwise the
2370 current file.
2372 .I %cd
2373 This is a special macro that is used to change the current directory
2374 to the directory specified in front of it.  This is used primarily as
2375 an interface to the
2376 .\"LINK2"
2377 Virtual File System\&.
2378 .\"Virtual File System"
2380 .I %view
2381 This macro is used to invoke the internal viewer.  This macro can be
2382 used alone, or with arguments.  If you pass any arguments to this
2383 macro, they should be enclosed in brackets.
2385 The arguments are:
2386 .I ascii
2387 to force the viewer into ascii mode;
2388 .I hex
2389 to force the viewer into hex mode;
2390 .I nroff
2391 to tell the viewer that it should interpret the bold and underline
2392 sequences of nroff;
2393 .I unformatted
2394 to tell the viewer to not interpret nroff commands for making the text
2395 bold or underlined.
2397 .I %%
2398 The % character
2400 .I %{some text}
2401 Prompt for the substitution. An input box is shown and the text inside
2402 the braces is used as a prompt. The macro is substituted by the text
2403 typed by the user. The user can press ESC or F10 to cancel. This macro
2404 doesn't work on the command line yet.
2406 .I %var{ENV:default}
2407 If environment variable
2408 .I ENV
2409 is unset, the
2410 .I default
2411 is substituted.  Otherwise, the value of
2412 .I ENV
2413 is substituted.
2414 .\"NODE "  The subshell support"
2415 .SH "  The subshell support"
2416 The subshell support is a compile time option, that works with the
2417 shells: bash, tcsh and zsh.
2419 When the subshell code is activated the Midnight Commander will
2420 spawn a concurrent copy of your shell (the one defined in the
2421 .B SHELL
2422 variable and if it is not defined, then the one in the /etc/passwd
2423 file) and run it in a pseudo terminal, instead of invoking a new shell
2424 each time you execute a command, the command will be passed to the
2425 subshell as if you had typed it.  This also allows you to change the
2426 environment variables, use shell functions and define aliases that are
2427 valid until you quit the Midnight Commander.
2429 If you are using
2430 .B bash
2431 you can specify startup
2432 commands for the subshell in your ~/.local/share/mc/bashrc file and
2433 special keyboard maps in the ~/.local/share/mc/inputrc file.
2434 .B tcsh
2435 users may specify startup commands in the ~/.local/share/mc/tcshrc file.
2437 When the subshell code is used, you can suspend applications at any
2438 time with the sequence C\-o and jump back to the Midnight Commander, if
2439 you interrupt an application, you will not be able to run other
2440 external commands until you quit the application you interrupted.
2442 An extra added feature of using the subshell is that the prompt
2443 displayed by the Midnight Commander is the same prompt that you are
2444 currently using in your shell.
2447 .\"LINK2"
2448 OPTIONS
2449 .\"OPTIONS"
2450 section has more information on how you can control the subshell code.
2451 .\"NODE "Chmod"
2452 .SH "Chmod"
2453 The Chmod window is used to change the attribute bits in a group of
2454 files and directories.  It can be invoked with the C\-x c key combination.
2456 The Chmod window has two parts \-
2457 .I Permissions
2459 .IR File .
2461 In the File section are displayed the name of the file or directory
2462 and its permissions in octal form, as well as its owner and group.
2464 In the Permissions section there is a set of check buttons which
2465 correspond to the file attribute bits.  As you change the attribute
2466 bits, you can see the octal value change in the File section.
2468 To move between the widgets (buttons and check buttons) use the
2469 .I arrow keys
2470 or the
2471 .I Tab
2472 key.  To change the state of the check buttons or to select a button
2474 .I Space.
2475 You can also use the hotkeys on the buttons to quickly activate them.
2476 Hotkeys are shown as highlighted letters on the buttons.
2478 To set the attribute bits, use the Enter key.
2480 When working with a group of files or directories, you just click on
2481 the bits you want to set or clear.  Once you have selected the bits
2482 you want to change, you select one of the action buttons (Set marked
2483 or Clear marked).
2485 Finally, to set the attributes exactly to those specified, you can use
2487 .B [Set all]
2488 button, which will act on all the tagged files.
2490 .B [Marked all]
2491 set only marked attributes to all selected files
2493 .B [Set marked]
2494 set marked bits in attributes of all selected files
2496 .B [Clean marked]
2497 clear marked bits in attributes of all selected files
2499 .B [Set]
2500 set the attributes of one file
2502 .B [Cancel]
2503 cancel the Chmod command
2504 .\"NODE "Chown"
2505 .SH "Chown"
2506 The Chown command is used to change the owner/group of a file. The hot
2507 key for this command is C\-x o.
2508 .\"NODE "Advanced Chown"
2509 .SH "Advanced Chown"
2510 The Advanced Chown command is the
2511 .\"LINK2"
2512 Chmod
2513 .\"Chmod"
2515 .\"LINK2"
2516 Chown
2517 .\"Chown"
2518 command combined into one window. You can change the permissions and
2519 owner/group of files at once.
2520 .\"NODE "File Operations"
2521 .SH "File Operations"
2522 When you copy, move or delete files the Midnight Commander shows the
2523 file operations dialog.  It shows the files currently being processed
2524 and uses up to three progress bars.  The file bar indicates the
2525 percentage of the current file that has been processed so far.  The
2526 count bar shows how many of the tagged files have been handled.  The
2527 bytes bar indicates the percentage of the total size of the tagged files
2528 that has been handled.  If the verbose option is off, the file and bytes
2529 bars are not shown.
2531 There are two buttons at the bottom of the dialog. Pressing the Skip
2532 button will skip the rest of the current file. Pressing the Abort
2533 button will abort the whole operation, the rest of the files are
2534 skipped.
2536 There are three other dialogs which you can run into during the file
2537 operations.
2539 The error dialog informs about error conditions and has three choices.
2540 Normally you select either the Skip button to skip the file or the Abort
2541 button to abort the operation altogether.  You can also select the Retry
2542 button if you fixed the problem from another terminal.
2544 The replace dialog is shown when you attempt to copy or move a file on
2545 the top of an existing file.  The dialog shows the dates and sizes of
2546 the both files.  Press the Yes button to overwrite the file, the No
2547 button to skip the file, the All button to overwrite all the files, the
2548 None button to never overwrite and the Update button to overwrite if the
2549 source file is newer than the target file.  You can abort the whole
2550 operation by pressing the Abort button.
2552 The recursive delete dialog is shown when you try to delete a directory
2553 which is not empty.  Press the Yes button to delete the directory
2554 recursively, the No button to skip the directory, the All button to
2555 delete all the directories and the None button to skip all the non\-empty
2556 directories.  You can abort the whole operation by pressing the Abort
2557 button.  If you selected the Yes or All button you will be asked for a
2558 confirmation.  Type "yes" only if you are really sure you want to do the
2559 recursive delete.
2561 If you have tagged files and perform an operation on them only the files
2562 on which the operation succeeded are untagged. Failed and skipped files
2563 are left tagged.
2564 .\"NODE "Mask Copy/Rename"
2565 .SH "Mask Copy/Rename"
2566 The copy/move operations let you translate the names of files in an
2567 easy way.  To do it, you have to specify the correct source mask and
2568 usually in the trailing part of the destination specify some wildcards.
2569 All the files matching the source mask are copied/renamed according to
2570 the target mask.  If there are tagged files, only the tagged files
2571 matching the source mask are renamed.
2573 There are other options which you can set:
2575 .B Follow links
2577 determines whether make the symlinks and hardlinks in the source
2578 directory (recursively in subdirectories) new links in the target
2579 directory or whether would you like to copy their content.
2581 .B Dive into subdirs
2583 determines the behavior when the source directory is about to be copied,
2584 but the target directory already exists.  The default action is to copy
2585 the contents of the source directory into the target directory.
2586 Enabling this option causes copying the source directory itself into the
2587 target directory.
2589 For example, you want to copy directory
2590 .I /foo
2591 containing file
2592 .I bar
2594 .IR /bla/foo ,
2595 which is an already existing directory.  Normally (when
2596 .B Dive into subdirs
2597 is not set), mc would copy file
2598 .I /foo/bar
2599 into the file
2600 .IR /bla/foo/bar .
2601 By enabling this option the
2602 .I /bla/foo/foo
2603 directory will be created, and
2604 .I /foo/bar
2605 will be copied into
2606 .IR /bla/foo/foo/bar .
2608 .B Preserve attributes
2610 determines whether to preserve the permissions, timestamps and (if you
2611 are root) the ownership of the original files.  If this option is not
2612 set, the current value of the umask will be respected.
2614 .B Use shell patterns
2616 When this option is on you can use the '*' and '?' wildcards in the source
2617 mask. They work like they do in the shell. In the target mask only the '*'
2618 and '\\<digit>' wildcards are allowed. The first '*' wildcard in the target
2619 mask corresponds to the first wildcard group in the source mask,
2620 the second '*' corresponds to the second group and so on.  The '\\1' wildcard
2621 corresponds to the first wildcard group in the source mask, the '\\2' wildcard
2622 corresponds to the second group and so on all the way up to '\\9'.
2623 The '\\0' wildcard is the whole filename of the source file.
2625 Two examples:
2627 If the source mask is "*.tar.gz", the destination is "/bla/*.tgz" and the
2628 file to be copied is "foo.tar.gz", the copy will be "foo.tgz" in "/bla".
2630 Suppose you want to swap basename and extension so that "file.c" would
2631 become "c.file" and so on.  The source mask for this is "*.*" and the
2632 destination is "\\2.\\1".
2634 .B Use shell patterns off
2636 When the shell patterns option is off the MC doesn't do automatic
2637 grouping anymore. You must use '\\(...\\)' expressions in the source
2638 mask to specify meaning for the wildcards in the target mask. This is
2639 more flexible but also requires more typing. Otherwise target masks
2640 are similar to the situation when the shell patterns option is on.
2642 Two examples:
2644 If the source mask is "^\\(.*\\)\\.tar\\.gz$", the destination is
2645 "/bla/*.tgz" and the file to be copied is "foo.tar.gz", the copy
2646 will be "/bla/foo.tgz".
2648 Let's suppose you want to swap basename and extension so that "file.c"
2649 will become "c.file" and so on. The source mask for this is
2650 "^\\(.*\\)\\.\\(.*\\)$" and the destination is "\\2.\\1".
2652 .B Case Conversions
2654 You can also change the case of the filenames.  If you use '\\u'
2655 or '\\l' in the target mask, the next character will be converted to
2656 uppercase or lowercase correspondingly.
2658 If you use '\\U' or '\\L' in the target mask, the next characters will
2659 be converted to uppercase or lowercase correspondingly up to the
2660 next '\\E' or next '\\U', '\\L' or the end of the file name.
2662 The '\\u' and '\\l' are stronger than '\\U' and '\\L'.
2664 For example, if the source mask is '*' (
2665 .I Use shell patterns
2666 on) or '^\\(.*\\)$' (
2667 .I Use shell patterns
2668 off) and the target mask is '\\L\\u*' the file names will be converted
2669 to have initial upper case and otherwise lower case.
2671 You can also use '\\' as a quote character. For example, '\\\\' is
2672 a backslash and '\\*' is an asterisk.
2674 .B Stable symlinks
2676 commands Midnight Commander, that it should change symlinks in the target,
2677 so that they'll point to the same location as it did before. With absolute
2678 symbolic links this does nothing, but if you have a relative one, it will
2679 recompute its value, adding necessary ../ and other directory parts and making
2680 the value as short as possible (most modern filesystems keep short symlinks
2681 inside inodes and thus don't waste much disk space).
2683 .\"NODE "Select/Unselect Files"
2684 .SH "Select/Unselect Files"
2685 The dialog of group of files and directories selection or uselection.
2687 .\"LINK2"
2688 input line
2689 .\"Input Line Keys"
2690 allow enter the regular expression of filenames that will be
2691 selected/unselected.
2693 When
2694 .I Files only
2695 checkbox is on, only files will be selected.  If
2696 .I Files only
2697 is off, as files as directories will be selected.
2698 When
2699 .I Shell Patterns
2700 checkbox is on, the regular expression is much like the filename globbing
2701 in the shell (* standing for zero or more characters and ?  standing
2702 for one character). If
2703 .I Shell Patterns
2704 is off, then the tagging of files is done with normal regular
2705 expressions (see ed (1)). When
2706 .I Case sensitive
2707 checkbox is on, the selection will be case sensitive characters.
2709 .I Case sensitive
2710 is off, the case will be ignored.
2711 .\"NODE "Diff Viewer"
2712 .SH "Internal Diff Viewer"
2713 The mcdiff is a visual diff tool. You can compare two files and edit them
2714 in\-place (diffs are updated dynamically). You can browse and view a working
2715 copy from popular version control systems (GIT, Subversion, etc).
2717 Following shortcuts are available in internal diff viewer of Midnight
2718 Commander.
2720 .B F1
2721 Invoke the built\-in hypertext help viewer.
2723 .B F2
2724 Save modified files.
2726 .B F4
2727 Edit file of the left panel in the internal editor.
2729 .B F14
2730 Edit file of the right panel in the internal editor.
2732 .B F5
2733 Merge the current hunk. Only the current hunk will be merged.
2735 .B F7
2736 Start search.
2738 .B F17
2739 Continue search.
2741 .B F10, Esc, q
2742 Exit from diff viewer.
2744 .B Alt\-s, s
2745 Toggle show of hunk status.
2747 .B Alt\-n, l
2748 Toggle show of line numbers.
2750 .B f
2751 Maximize left panel.
2753 .B \=
2754 Make panels equal in width.
2756 .B \>
2757 Reduce the size of the right panel.
2759 .B \<
2760 Reduce the size of the left panel.
2762 .B c
2763 Toggle show of trailing carriage return (CR) symbol as ^M.
2765 .B 2, 3, 4, 8
2766 Set tabulation size
2768 .B C\-u
2769 Swap contents of diff panels.
2771 .B C\-r
2772 Refresh the screen.
2774 .B C\-o
2775 Switch to the subshell and show the command screen.
2777 .B Enter, Space, n
2778 Find next diff hunk.
2780 .B Backspace, p
2781 Find previous diff hunk.
2783 .B g
2784 Go to line.
2786 .B Down
2787 Scroll one line forward.
2789 .B Up
2790 Scroll one line backward.
2792 .B PageUp
2793 Move one page up.
2795 .B PageDown
2796 Mves one page down.
2798 .B Home, A1
2799 Moves to the line beginning.
2801 .B End
2802 Moves to the line end.
2804 .B C\-Home
2805 Move to the file beginning.
2807 .B C\-End, C1
2808 Move to the file end.
2809 .\"NODE "Internal File Viewer"
2810 .SH "Internal File Viewer"
2811 The internal file viewer provides two display modes: ASCII and hex.
2812 To toggle between modes, use the F4 key.
2814 The viewer will try to use the best method provided by your system or
2815 the file type to display the information.
2816 Some character sequences, which appear most often in preformatted manual
2817 pages, are displayed bold and underlined, thus making a pretty display
2818 of your files.
2820 When in hex mode, the search function accepts text in quotes and
2821 constant numbers.  Text in quotes is matched exactly after removing
2822 the quotes.  Each number matches one byte.  You can mix quoted text
2823 with constants like this:
2826 "String" \-1 0xBB 012 "more text"
2829 Note that 012 is an octal number.  \-1 is converted to 0xFF.
2831 Here is a listing of the actions associated with each key that the
2832 Midnight Commander handles in the internal file viewer.
2834 .B F1
2835 Invoke the built\-in hypertext help viewer.
2837 .B F2
2838 Toggle the wrap mode.
2840 .B F4
2841 Toggle the hex mode.
2843 .B F5
2844 Goto line.  This will prompt you for a line number and will display
2845 that line.
2847 .B F6, /.
2848 Regular expression search.
2850 .B ?,
2851 Reverse regular expression search.
2853 .B F7
2854 Normal search / hex mode search.
2856 .B C\-s, F17, n.
2857 Start normal search if there was no previous search expression else
2858 find next match.
2860 .B C\-r.
2861 Start reverse search if there was no previous search expression else
2862 find next match.
2864 .B F8
2865 Toggle Raw/Parsed mode: This will show the file as found on disk or if
2866 a processing filter has been specified in the mc.ext file, then the
2867 output from the filter. Current mode is always the other than written
2868 on the button label, since on the button is the mode which you enter
2869 by that key.
2871 .B F9
2872 Toggle the format/unformat mode: when format mode is on the viewer
2873 will interpret some string sequences to show bold and underline with
2874 different colors. Also, on button label is the other mode than current.
2876 .B F10, Esc.
2877 Exit the internal file viewer.
2879 .B next\-page, space, C\-v.
2880 Scroll one page forward.
2882 .B prev\-page, Alt\-v, C\-b, Backspace.
2883 Scroll one page backward.
2885 .B down\-key
2886 Scroll one line forward.
2888 .B up\-key
2889 Scroll one line backward.
2891 .B C\-l
2892 Refresh the screen.
2894 .B C\-o
2895 Switch to the subshell and show the command screen.
2897 .B "[n] m"
2898 Set the mark n.
2900 .B "[n] r"
2901 Jump to the mark n.
2903 .B C\-f
2904 Jump to the next file.
2906 .B C\-b
2907 Jump to the previous file.
2909 .B Alt\-r
2910 Toggle the ruler.
2912 .B Alt\-e
2913 to change charset of displayed text may use M\-e (Alt\-e).
2914 Recoding is made from selected codepage into system codepage. To
2915 cancel the recoding you may select "<No translation>" in charset
2916 selection dialog.
2918 It's possible to instruct the file viewer how to display a file, look
2919 at the
2920 .\"LINK2"
2921 Extension File Edit section
2922 .\"Extension File Edit"
2924 .\"NODE "Internal File Editor"
2925 .SH "Internal File Editor"
2926 The internal file editor is a full\-featured full screen editor.  It can
2927 edit files up to 64 megabytes.  It is possible to edit binary files.
2928 The internal file editor is invoked using
2929 .B F4
2930 if the
2931 .I use_internal_edit
2932 option is set in the initialization file.
2934 The features it presently supports are: block copy, move, delete, cut,
2935 paste; key for key undo; pull\-down menus; file insertion; macro
2936 commands; regular expression search and replace; shift\-arrow text highlighting
2937 (if supported by the terminal); insert\-overwrite toggle; word wrap;
2938 autoindent; tunable tab size; syntax highlighting for various file
2939 types; and an option to pipe text blocks through shell commands like
2940 indent and ispell.
2942 Sections:
2944 .\"LINK2"
2945 Options of editor in ini\-file
2946 .\"Internal File Editor / options"
2948 The editor is very easy to use and requires no tutoring. To see what
2949 keys do what, just consult the appropriate pull\-down menu. Other keys
2950 are: Shift movement keys do text highlighting.
2951 .B Ctrl\-Ins
2952 copies to the file
2953 .B mcedit.clip
2955 .B Shift\-Ins
2956 pastes from mcedit.clip.
2957 .B Shift\-Del
2958 cuts to
2959 .BR mcedit.clip ,
2961 .B Ctrl\-Del
2962 deletes highlighted text. Mouse highlighting also works, and you
2963 can override the mouse as usual by holding down the shift key
2964 while dragging the mouse to let normal terminal mouse highlighting
2965 work.
2967 To define a macro, press
2968 .B Ctrl\-R
2969 and then type out the key
2970 strokes you want to be executed. Press
2971 .B Ctrl\-R
2972 again when finished. You can then assign the macro to any key you
2973 like by pressing that key. The macro is executed when you press
2974 .B Ctrl\-A
2975 and then the assigned key. The macro is also executed if
2976 you press Meta, Ctrl, or Esc and the assigned key, provided that the
2977 key is not used for any other function. Once defined, the macro
2978 commands go into the file
2979 .B ~/.local/share/mc/mcedit/mcedit.macros
2980 You can delete a macro by deleting the
2981 appropriate line in this file.
2983 To change charset of displayed text may use M\-e (Alt\-e).
2984 Recoding is made from selected codepage into system codepage. To
2985 cancel the recoding you may select "<No translation>" in charset
2986 selection dialog.
2988 .B F19
2989 will format the currently highlighted block (plain text or
2990 .B C
2992 .B C++
2993 code or another). This is controlled by the
2994 file
2995 .B %prefix%/share/mc/edit.indent.rc
2996 which is copied to
2997 .B ~/.local/share/mc/mcedit/edit.indent.rc
2998 in your home directory the first time you use it.
3000 The editor also displays non\-us characters (160+). When editing
3001 binary files, you should set
3002 .B display bits
3003 to 7 bits in the options menu to keep the spacing clean.
3005 .\"NODE "Internal File Editor / options"
3006 .SH "Options of editor in ini\-file"
3008 Some editor options of ini\-file are described in this section.
3009 Options are placed in [Midnight\-Commander] section
3011 .I editor_wordcompletion_collect_entire_file
3012 Search autocomplete candidates in entire of file or just from
3013 begin of file to cursor position (0)
3015 .\"NODE "Screen selector"
3016 .SH "Screen selector"
3017 Midnight Commander supports running many internal modules (such as
3018 editor, viewer and diff viewer) simultaneously and switching between
3019 them without closing open files. Using several file managers at a time,
3020 however, is not currently supported.
3022 Let's call each of these modules a screen. There are three ways to
3023 switch between screens, using one of these global shortcuts:
3025 .B Alt\-}
3026 switch to the next screen;
3028 .B Alt\-{
3029 switch to the previous screen;
3031 .B Alt\-`
3032 open a dialog window with the list of currently open screens (or use the
3033 "Screen list" menu item).
3034 .\"NODE "Completion"
3035 .SH "Completion"
3036 Let the Midnight Commander type for you.
3038 Attempt to perform completion on the text before current position.  MC
3039 attempts completion treating the text as variable (if the text begins
3040 with
3041 .BR $ ),
3042 username (if the text begins with
3043 .BR ~ ),
3044 hostname (if the text begins with
3045 .BR @ )
3046 or command (if you are on the command line in the position where you
3047 might type a command, possible completions then include shell reserved
3048 words and shell built\-in commands as well) in turn.  If none of these
3049 matches, filename completion is attempted.
3051 Filename, username, variable and hostname completion works on all input
3052 lines, command completion is command line specific.  If the completion
3053 is ambiguous (there are more different possibilities), MC beeps and the
3054 following action depends on the setting of the
3055 .I Complete: show all
3056 option in the
3057 .\"LINK2"
3058 Configuration
3059 .\"Configuration"
3060 dialog.  If it is enabled, a list of all possibilities pops up next to
3061 the current position and you can select with the arrow keys and
3062 .B Enter
3063 the correct entry.  You can also type the first letters in which the
3064 possibilities differ to move to a subset of all possibilities and
3065 complete as much as possible.  If you press
3066 .B Alt\-Tab
3067 again, only the subset will be shown in the listbox, otherwise the first
3068 item which matches all the previous characters will be highlighted.  As
3069 soon as there is no ambiguity, dialog disappears, but you can hide it by
3070 canceling keys
3071 .BR Esc ,
3072 .B F10
3073 and left and right arrow keys. If
3074 .\"LINK2"
3075 Complete: show all
3076 .\"Configuration"
3077 is disabled, the dialog pops up only if you press
3078 .B Alt\-Tab
3079 for the second time, for the first time MC just beeps.
3080 .\"NODE "Virtual File System"
3081 .SH "Virtual File System"
3082 The Midnight Commander is provided with a code layer to access the file
3083 system; this code layer is known as the virtual file system switch.  The
3084 virtual file system switch allows the Midnight Commander to manipulate
3085 files not located on the Unix file system.
3087 Currently the Midnight Commander is packaged with some Virtual File
3088 Systems (VFS): the
3089 .I local
3090 file system, used for accessing the regular Unix file system; the
3091 .IR ftpfs ,
3092 used to manipulate files on remote systems with the FTP protocol; the
3093 .IR tarfs ,
3094 used to manipulate tar and compressed tar files; the
3095 .IR undelfs ,
3096 used to recover deleted files on ext2 file systems (the default file
3097 system for Linux systems),
3098 .I fish
3099 (for manipulating files over shell connections such as rsh and ssh).
3100 If the code was compiled with
3101 .I sftpfs
3102 (for manipulating files over SFTP connections).
3103 If the code was compiled with
3104 .I smbfs
3105 support, you can manipulate files on remote systems with the SMB (CIFS)
3106 protocol.
3108 A generic
3109 .I extfs
3110 (EXTernal virtual File System) is provided in order to easily expand
3111 VFS capabilities using scripts and external software.
3113 The VFS switch code will interpret all of the path names used and will
3114 forward them to the correct file system, the formats used for each one
3115 of the file systems is described later in their own section.
3116 .\"NODE "  FTP File System"
3117 .SH "  FTP File System"
3118 The FTP File System (ftpfs) allows you to manipulate files on remote
3119 machines.  To actually use it, you can use the
3120 .I FTP link
3121 item in the menu or directly change your current directory using the
3122 .I cd
3123 command to a path name that looks like this:
3125 .I ftp://[!][user[:pass]@]machine[:port][remote\-dir]
3128 .IR user ,
3129 .I port
3131 .I remote\-dir
3132 elements are optional.  If you specify the
3133 .I user
3134 element, the Midnight Commander will login to the remote machine as that
3135 user, otherwise it will use anonymous login or the login name from the
3136 .I ~/.netrc
3137 file.  The optional
3138 .I pass
3139 element is the password used for the connection.  Using the password in
3140 the VFS directory name is not recommended, because it can appear on the
3141 screen in clear text and can be saved to the directory history.
3143 To enable using FTP proxy, prepend
3144 .B !
3145 (an exclamation sign) to the hostname.
3147 Examples:
3150     ftp://ftp.nuclecu.unam.mx/linux/local
3151     ftp://tsx\-11.mit.edu/pub/linux/packages
3152     ftp://!behind.firewall.edu/pub
3153     ftp://guest@remote\-host.com:40/pub
3154     ftp://miguel:xxx@server/pub
3157 Please check the
3158 .\"LINK2"
3159 Virtual File System
3160 .\"Virtual FS"
3161 dialog box for ftpfs options.
3162 .\"NODE "  Tar File System"
3163 .SH "  Tar File System"
3164 The tar file system provides you with read\-only access to your tar
3165 files and compressed tar files by using the chdir command.  To change
3166 your directory to a tar file, you change your current directory to the
3167 tar file by using the following syntax:
3169 .I /filename.tar/utar://[dir\-inside\-tar]
3171 The mc.ext file already provides a shortcut for tar files, this means
3172 that usually you just point to a tar file and press return to enter
3173 into the tar file, see the
3174 .\"LINK2"
3175 Extension File Edit
3176 .\"Extension File Edit"
3177 section for details on how this is done.
3179 Examples:
3182     mc\-3.0.tar.gz/utar://mc\-3.0/vfs
3183     /ftp/GCC/gcc\-2.7.0.tar/utar://
3186 The latter specifies the full path of the tar archive.
3187 .\"NODE "  FIle transfer over SHell filesystem"
3188 .SH "  FIle transfer over SHell filesystem"
3189 The fish file system is a network based file system that allows you to
3190 manipulate the files in a remote machine as if they were local. To use
3191 this, the other side has to either run fish server, or has to have
3192 bash\-compatible shell.
3194 To connect to a remote machine, you just need to chdir
3195 into a special directory which name is in the following
3196 format:
3198 .I sh://[user@]machine[:options]/[remote\-dir]
3201 .I user,
3202 .I options
3204 .I remote\-dir
3205 elements are optional.  If you specify the
3206 .I user
3207 element, the Midnight Commander will try to login on the remote
3208 machine as that user, otherwise it will use your login name.
3210 The available
3211 .I options
3212 are:
3214   'C' \- use compression;
3215   'r' \- use rsh instead of ssh;
3216   port \- specify the port used by remote server.
3218 If the
3219 .I remote\-dir
3220 element is present, your current directory on the remote machine will be
3221 set to this one.
3223 Examples:
3226     sh://onlyrsh.mx:r/linux/local
3227     sh://joe@want.compression.edu:C/private
3228     sh://joe@noncompressed.ssh.edu/private
3229     sh://joe@somehost.ssh.edu:2222/private
3231 .\"NODE "  SFTP (SSH File Transfer Protocol) filesystem"
3232 .SH "  SFTP (SSH File Transfer Protocol) filesystem"
3233 The SFTP file system is a network based file system that allows you to
3234 manipulate the files in a remote machine as if they were local.
3236 To connect to a remote machine, you just need to chdir
3237 into a special directory which name is in the following
3238 format:
3240 .I sftp://[user@]machine:[port]/[remote\-dir]
3243 .I user,
3244 .I port
3246 .I remote\-dir
3247 elements are optional.  If you specify the
3248 .I user
3249 element, the Midnight Commander will try to login on the remote
3250 machine as that user, otherwise it will use your login name.
3251 .I port
3252 \- specify the port used by remote server (22 by default).
3253 If the
3254 .I remote\-dir
3255 element is present, your current directory on the remote machine will be
3256 set to this one.
3258 Examples:
3261     sftp://onlyrsh.mx/linux/local
3262     sftp://joe:password@want.compression.edu/private
3263     sftp://joe@noncompressed.ssh.edu/private
3264     sftp://joe@somehost.ssh.edu:2222/private
3266 .\"NODE "  Undelete File System"
3267 .SH "  Undelete File System"
3268 On Linux systems, if you asked configure to use the ext2fs undelete
3269 facilities, you will have the undelete file system available.
3270 Recovery of deleted files is only available on ext2 file systems.  The
3271 undelete file system is just an interface to the ext2fs library to
3272 retrieve all of the deleted files names on an ext2fs and provides and
3273 to extract the selected files into a regular partition.
3275 To use this file system, you have to chdir into the special file name
3276 formed by the "undel://" prefix and the file name where the actual
3277 file system resides.
3279 For example, to recover deleted files on the second partition of the
3280 first SCSI disk on Linux, you would use the following path name:
3283     undel://sda2
3286 It may take a while for the undelfs to load the required information
3287 before you start browsing files there.
3288 .\"NODE "  SMB File System"
3289 .SH "  SMB File System"
3290 The smbfs allows you to manipulate files on remote machines with SMB
3291 (or CIFS) protocol.  These include Windows for Workgroups,
3292 Windows 9x/ME/XP, Windows NT, Windows 2000 and Samba.
3293 To actually use it, you may try to use the panel command "SMB link..."
3294 (accessible from the menubar) or you may directly change your current
3295 directory to it using the cd command to a path name that looks like this:
3297 .I smb://[user@]machine[/service][/remote\-dir]
3300 .IR user ,
3301 .I service
3303 .I remote\-dir
3304 elements are optional.
3306 .IR user ,
3307 .I domain
3309 .I password
3310 can be specified in an input dialog.
3312 Examples:
3315     smb://machine/Share
3316     smb://other_machine
3317     smb://guest@machine/Public/Irlex
3319 .\"NODE "  EXTernal File System"
3320 .SH "  EXTernal File System"
3321 .B extfs
3322 allows you to integrate numerous features and file types into GNU Midnight
3323 Commander in an easy way, by writing scripts.
3325 Extfs filesystems can be divided into two categories:
3327 1. Stand\-alone filesystems, which are not associated with any existing
3328 file.  They represent certain system\-wide data as a directory tree.
3329 You can invoke them by typing
3330 .RI ' "cd fsname://" '
3331 where fsname is an extfs short name (see below).  Examples of such
3332 filesystems include audio (list audio tracks on the CD) or apt (list of
3333 all Debian packages in the system).
3335 For example, to list CD\-Audio tracks on your CD\-ROM drive, type
3338   cd audio://
3341 2. 'Archive' filesystems (like rpm, patchfs and more), which represent
3342 contents of a file as a directory tree.  It can consist of 'real' files
3343 compressed in an archive (urar, rpm) or virtual files, like messages
3344 in a mailbox (mailfs) or parts of a patch (patchfs).  To access such
3345 filesystems
3346 .RI ' fsname:// '
3347 should be appended to the archive name.  Note that the archive itself
3348 can be on another vfs.
3350 For example, to list contents of a zip archive documents.zip type
3353   cd documents.zip/uzip://
3356 In many aspects, you could treat extfs like any other directory.  For
3357 instance, you can add it to the hotlist or change to it from directory
3358 history.  An important limitation is that you cannot invoke shell
3359 commands inside extfs, just like any other non\-local VFS.
3361 Common extfs scripts included with Midnight Commander are:
3363 .B a
3364 access 'A:' DOS/Windows diskette
3365 .RI ( "cd a://" ).
3367 .B apt
3368 front end to Debian's APT package management system
3369 .RI ( "cd apt://" ).
3371 .B audio
3372 audio CD ripping and playing
3373 .RI ( "cd audio://"
3375 .IR "cd device/audio://" ).
3377 .B bpp
3378 package of Bad Penguin GNU/Linux distribution
3379 .RI ( "cd file.bpp/bpp://" ).
3381 .B deb
3382 package of Debian GNU/Linux distribution
3383 .RI ( "cd file.deb/deb://" ).
3385 .B dpkg
3386 Debian GNU/Linux installed packages
3387 .RI ( "cd deb://" ).
3389 .B hp48
3390 view and copy files to/from a HP48 calculator
3391 .RI ( "cd hp48://" ).
3393 .B lslR
3394 browsing of lslR listings as found on many FTPs
3395 .RI ( "cd filename/lslR://" ).
3397 .B mailfs
3398 mbox\-style mailbox files support
3399 .RI ( "cd mailbox/mailfs://" ).
3401 .B patchfs
3402 extfs to handle unified and context diffs
3403 .RI ( "cd filename/patchfs://" ).
3405 .B rpm
3406 RPM package
3407 .RI ( "cd filename/rpm://" ).
3409 .B rpms
3410 RPM database management
3411 .RI ( "cd rpms://" ).
3413 .B ulha, urar, uzip, uzoo, uar, uha
3414 archivers
3415 .RI ( "cd archive/xxxx://"
3416 where xxxx is one of:
3417 .IR ulha ,
3418 .IR urar ,
3419 .IR uzip ,
3420 .IR uzoo ,
3421 .IR uar ,
3422 .IR uha ).
3424 You could bind file type/extension to specified extfs as described in the
3425 .\"LINK2"
3426 Extension File Edit
3427 .\"Extension File Edit"
3428 section.  Here is an example entry for Debian packages:
3431   regex/\.deb$
3432           Open=%cd %p/deb://
3434 .\"NODE "Colors"
3435 .SH "Colors"
3436 The Midnight Commander will try to detect if your terminal supports
3437 color using the terminal database and your terminal name.  Sometimes
3438 it gets confused, so you may force color mode or disable color mode
3439 using the \-c and \-b flag respectively.
3441 If the program is compiled with the Slang screen manager instead of
3442 ncurses, it will also check the variable
3443 .B COLORTERM,
3444 if it is set, it has the same effect as the \-c flag.
3446 You may specify terminals that always force color mode
3447 by adding the
3448 .I color_terminals
3449 variable to the Colors section of the initialization file.  This will
3450 prevent the Midnight Commander from trying to detect if your terminal
3451 supports color.  Example:
3454 [Colors]
3455 color_terminals=linux,xterm
3456 color_terminals=terminal\-name1,terminal\-name2...
3459 The program can be compiled with both ncurses and slang, ncurses does
3460 not provide a way to force color mode: ncurses uses just the
3461 information in the terminal database.
3463 The Midnight Commander provides a way to change the default colors.
3464 Currently the colors are configured using the environment variable
3465 .B MC_COLOR_TABLE
3466 or the Colors section in the initialization file.
3468 In the Colors section, the default color map is loaded from the
3469 .I base_color
3470 variable.  You can specify an alternate color map for a terminal by
3471 using the terminal name as the key in this section.  Example:
3474 [Colors]
3475 base_color=
3476 xterm=menu=magenta:marked=,magenta:markselect=,red
3479 The format for the color definition is:
3482   <keyword>=<fgcolor>,<bgcolor>,<attributes>:<keyword>=...
3485 The colors are optional, and the keywords are: normal, selected, disabled, marked,
3486 markselect, errors, input, inputmark, inputunchanged, commandlinemark,
3487 reverse, gauge, header, inputhistory, commandhistory. Button bar colors are:
3488 bbarhotkey, bbarbutton. Status bar color: statusbar. Menu colors are: menunormal,
3489 menusel, menuhot, menuhotsel, menuinactive. Dialog colors are: dnormal, dfocus,
3490 dhotnormal, dhotfocus, dtitle. Error dialog colors are: errdfocus, errdhotnormal,
3491 errdhotfocus, errdtitle.  Help colors are: helpnormal, helpitalic, helpbold,
3492 helplink, helpslink, helptitle.  Viewer color are: viewbold, viewunderline, viewselected.
3493 Editor colors are: editnormal, editbold, editmarked, editwhitespace, editlinestate.
3494 Popup menu colors are: pmenunormal, pmenusel, pmenutitle.
3496 .I header
3497 determines the color of panel header, the line that contains column titles
3498 and sort mode indicator.
3500 .I input
3501 determines the color of input lines used in query dialogs.
3503 .I gauge
3504 determines the color of the filled part of the progress bar (gauge),
3505 which is used to show the user the progress of file operations, such as
3506 copying.
3508 .I disabled
3509 determines the color of the widget that cannot be selected.
3511 The dialog boxes use the following colors:
3512 .I dnormal
3513 is used for the normal text,
3514 .I dfocus
3515 is the color used for the currently selected component,
3516 .I dhotnormal
3517 is the color used to differentiate the hotkey color in normal
3518 components, whereas the
3519 .I dhotfocus
3520 color is used for the highlighted color in the currently selected
3521 component.
3523 Menus use the same scheme but uses the menunormal, menusel, menuhot, menuhotsel
3524 and menuinactive tags instead.
3526 Help uses the following colors:
3527 .I helpnormal
3528 is used for normal text,
3529 .I helpitalic
3530 is used for text which is emphasized in italic in the manual page,
3531 .I helpbold
3532 is used for text which is emphasized in bold in the manual page,
3533 .I helplink
3534 is used for not selected hyperlinks and
3535 .I helpslink
3536 is used for selected hyperlink.
3538 Popup menu uses following colors:
3539 .I pmenunormal
3540 is used for non-selected menu items and as a main color of popup menu window,
3541 .I pmenusel
3542 is used for selected menu item,
3543 .I pmenutitle
3544 is used for popup menu title.
3546 The possible colors are: black, gray, red, brightred, green,
3547 brightgreen, brown, yellow, blue, brightblue, magenta, brightmagenta,
3548 cyan, brightcyan, lightgray and white. And there is a special keyword
3549 for transparent background. It is 'default'. The 'default' can only be
3550 used for background color. Another special keyword "base" means mc's main
3551 colors.  When 256 colors are available, they can be specified either as
3552 color16 to color255, or as rgb000 to rgb555 and gray0 to gray23. Example:
3555 [Colors]
3556 base_color=normal=white,default:marked=magenta,default
3559 Attributes can be any of bold, underline, reverse and blink, appended by a
3560 plus sign if more than one are desired.  The special word "none" means no
3561 attributes, without attempting to fall back to base_color.  Example:
3564 menuhotsel=yellow;black;bold+underline
3567 .\"NODE "Skins"
3568 .SH "Skins"
3569 You can change the appearance of Midnight Commander.
3570 To do this, you must specify a file that contain descriptions of colors
3571 and lines to draw boxes. Redefining of the colors is entirely compatible
3572 with the assignment of colors, as described in Section
3573 .\"LINK2"
3574 Colors\&.
3575 .\"Colors"
3577 If your skin contains any of 256\-color definitions, you should define
3578 the '256colors' key set to TRUE value in [skin] section.
3581 A skin\-file is searched on the following algorithm (to the first one found):
3584 1) command line option
3585 .B \-S \<skin\>
3587 .B \-\-skin=\<skin\>
3589 2) Environment variable
3590 .B MC_SKIN
3592 3) Parameter
3593 .B skin
3594 in section
3595 .B [Midnight\-Commander]
3596 in config file.
3598 4) File
3599 .B %sysconfdir%/mc/skins/default.ini
3601 5) File
3602 .B %prefix%/share/mc/skins/default.ini
3605 Command line option, environment variable and parameter in config file may
3606 contain the absolute path to the skin\-file (with the extension \.ini
3607 or without it). Search of skin\-file will occur in (to the first one found):
3610 .B ~/.local/share/mc/skins/
3613 .B @sysconfdir@/mc/skins/
3616 .B %prefix%/share/mc/skins/
3620 For getting extended info, refer to:
3622 .\"LINK2"
3623 Description of section and parameters
3624 .\"Skins sections"
3626 .\"LINK2"
3627 Color pair definitions
3628 .\"Skins colors"
3630 .\"LINK2"
3631 Draw lines
3632 .\"Skins lines"
3634 .\"LINK2"
3635 Compatibility
3636 .\"Skins oldcolors"
3639 .\"NODE "  Skins sections"
3640 .SH "  Description of section and parameters"
3642 Section
3643 .B [skin]
3644 contain metainfo for skin\-file. Parameter
3645 .I description
3646 contain short text about skin.
3649 Section
3650 .B [filehighlight]
3651 contain descriptions of color pairs for filenames highlighting.
3652 Name of parameters must be equal to names of sections into
3653 filehighlight.ini file.
3655 .\"LINK2"
3656 Filenames Highlight
3657 .\"Filenames Highlight"
3658 for getting more info.
3661 Section
3662 .B [core]
3663 describes the elements that are used everywhere.
3665 .I _default_
3666 Default color pair. Used in all other sections if they not contain
3667 color definitions
3669 .I selected
3670 cursor
3672 .I marked
3673 selected data
3675 .I markselect
3676 cursor on selected data
3678 .I gauge
3679 color of the filled part of the progress bar
3681 .I input
3682 color of input lines used in query dialogs
3684 .I inputmark
3685 color of input selected text
3687 .I inputunhanged
3688 color of input text before first modification or cursor movement
3690 .I commandlinemark
3691 color of selected text in command line
3693 .I reverse
3694 reverse color
3696 Section
3697 .B [dialog]
3698 describes the elements that are placed on dialog windows (except error dialogs).
3700 .I _default_
3701 Default color for this section. Used [core]._default_ if not specified
3703 .I dfocus
3704 Color of active element (in focus)
3706 .I dhotnormal
3707 Color of hotkeys
3709 .I dhotfocus
3710 Color of hotkeys in focused element
3713 Section
3714 .B [error]
3715 describes the elements that are placed on error dialog windows
3717 .I _default_
3718 Default color for this section. Used [core]._default_ if not specified
3720 .I errdhotnormal
3721 Color of hotkeys
3723 .I errdhotfocus
3724 Color of hotkeys in focused element
3727 Section
3728 .B [menu]
3729 describes the elements that are placed in menu. This section describes
3730 system menu (called by F9) and user\-defined menus (called by F2 in panels
3731 and by F11 in editor).
3733 .I _default_
3734 Default color for this section. Used [core]._default_ if not specified
3736 .I entry
3737 Color of menu items
3739 .I menuhot
3740 Color of menu hotkeys
3742 .I menusel
3743 Color of active menu item (in focus)
3745 .I menuhotsel
3746 Color of menu hotkeys in focused menu item
3748 .I menuinactive
3749 Color of inactive menu
3752 Section
3753 .B [help]
3754 describes the elements that are placed on help window.
3756 .I _default_
3757 Default color for this section. Used [core]._default_ if not specified
3759 .I helpitalic
3760 Color pair for element with
3761 .B italic
3762 attribute
3764 .I helpbold
3765 Color pair for element with
3766 .B bold
3767 attribute
3769 .I helplink
3770 Color of links
3772 .I helpslink
3773 Color of active link (on focus)
3776 Section
3777 .B [editor]
3778 describes the colors of elements placed in editor.
3780 .I _default_
3781 Default color for this section. Used [core]._default_ if not specified
3783 .I editbold
3784 Color pair for element with
3785 .B bold
3786 attribute
3788 .I editmarked
3789 Color of selected text
3791 .I editwhitespace
3792 Color of tabs and trailing spaces highlighting
3794 .I editlinestate
3795 Color for line state area
3798 Section
3799 .B [viewer]
3800 describes the colors of elements placed in viewer.
3802 .I viewunderline
3803 Color pair for element with
3804 .B underline
3805 attribute
3807 .\"NODE "  Skins colors"
3808 .SH "  Color pair definitions"
3809 Any parameter in skin\-file contain definition of color pair.
3811 Color pairs described as two colors and the optional attributes
3812 separated by ';'. First field sets the foreground color, second
3813 field sets background color, third field sets the attributes.
3814 Any of the fields may be omitted, in this case value will be
3815 taken from default color pair (global color pair or from default
3816 color pair of this section).
3818 Example:
3821 [core]
3822     # green on black
3823     _default_=green;black
3824     # green (default) on blue
3825     selected=;blue
3826     # yellow on black (default)
3827     # underlined yellow on black (default)
3828     marked=yellow;;underline
3832 Possible colors (names) and attributes are described in
3833 .\"LINK2"
3834 Colors\&.
3835 .\"Colors"
3836 section.
3838 .\"NODE "  Skins lines"
3839 .SH "  Draw lines"
3840 Lines sets in section
3841 .B [Lines]
3842 into skin\-file. By default single lines are used, but you may redefine
3843 to usage of any utf\-8 symbols (like to lines, for example).
3845 .I WARNING!!!
3846 When you build Midnight Commander with the Ncurses screen library
3847 usage of drawing lines is limited!
3848 Possible only drawing a single lines.
3849 For all questions and comments please contact the developers of Ncurses.
3852 Descriptions of parameters
3853 .BR [Lines] :
3855 .I lefttop
3856 left\-top line fragment.
3858 .I righttop
3859 right\-top line fragment.
3861 .I centertop
3862 down branch of horizontal line
3864 .I centerbottom
3865 up branch of horizontal line
3867 .I leftbottom
3868 left\-bottom line fragment
3870 .I rightbottom
3871 right\-bottom line fragment
3873 .I leftmiddle
3874 right branch of vertical line
3876 .I rightmiddle
3877 left branch of vertical line
3879 .I centermiddle
3880 cross of lines
3882 .I horiz
3883 horizontal line
3885 .I vert
3886 vertical line
3888 .I thinhoriz
3889 thin horizontal line
3891 .I thinvert
3892 thin vertical line
3895 .\"NODE "  Skins oldcolors"
3896 .SH "  Compatibility"
3898 Appointment of color  by skin\-files fully compatible with
3899 the appointment of the colors described in
3900 .\"LINK2"
3901 Colors\&.
3902 .\"Colors"
3903 section.
3905 In this case, reassignment of colors has priority over the skin file and is
3906 complementary.
3908 .\"NODE "Filenames Highlight"
3909 .SH "Filenames Highlight"
3910 Section [filehighlight] in current skin\-file contains key names as
3911 highlight groups and values as color pairs. Color pairs is documented
3913 .\"LINK2"
3914 Skins
3915 .\"Skins"
3916 section.
3918 Rules of filenames highlight are placed in %prefix%/share/mc/filehighlight.ini file
3919 (~/.config/mc/filehighlight.ini).
3920 Name of section in this file must be equal to parameters names in
3921 [filehighlight] section (in current skin\-file).
3923 Keys in these groups are:
3925 .I type
3926 file type. If present, all other options are ignored.
3928 .I regexp
3929 regular expression. If present, 'extensions' option is ignored.
3931 .I extensions
3932 list of extensions of files. Separated by ';' sign.
3934 .I extensions_case
3935 (make sense only with 'extensions' parameter) make 'extensions'
3936 rule case sentitive (true) or not (false).
3938 `type' key may have values:
3940 \- FILE (all files)
3941   \- FILE_EXE
3942 \- DIR (all directories)
3943   \- LINK_DIR
3944 \- LINK (all links except stale link)
3945   \- HARDLINK
3946   \- SYMLINK
3947 \- STALE_LINK
3948 \- DEVICE (all device files)
3949   \- DEVICE_BLOCK
3950   \- DEVICE_CHAR
3951 \- SPECIAL (all special files)
3952   \- SPECIAL_SOCKET
3953   \- SPECIAL_FIFO
3954   \- SPECIAL_DOOR
3958 .\"NODE "Special Settings"
3959 .SH "Special Settings"
3960 Most of the Midnight Commander settings can be changed from the
3961 menus. However, there are a small number of settings which can only be
3962 changed by editing the setup file.
3964 These variables may be set in your ~/.config/mc/ini file:
3966 .I clear_before_exec
3967 By default the Midnight Commander clears the screen before executing a
3968 command.  If you would prefer to see the output of the command at the
3969 bottom of the screen, edit your ~/.config/mc/ini file and change the value of
3970 the field clear_before_exec to 0.
3972 .I confirm_view_dir
3973 If you press F3 on a directory, normally MC enters that directory.  If
3974 this flag is set to 1, then MC will ask for confirmation before changing
3975 the directory if you have files tagged.
3977 .I ftpfs_retry_seconds
3978 This value is the number of seconds the Midnight Commander will wait
3979 before attempting to reconnect to an FTP server that has denied the
3980 login.  If the value is zero, the login will no be retried.
3982 .I max_dirt_limit
3983 Specifies how many screen updates can be skipped at most in the internal
3984 file viewer.  Normally this value is not significant, because the code
3985 automatically adjusts the number of updates to skip according to the
3986 rate of incoming keystrokes.  However, on very slow machines or
3987 terminals with a fast keyboard auto repeat, a big value can make screen
3988 updates too jumpy.
3990 It seems that setting max_dirt_limit to 10 causes the best behavior,
3991 and that is the default value.
3993 .I mouse_move_pages_viewer
3994 Controls if scrolling with the mouse is done by pages or line by line
3995 on the internal file viewer.
3997 .I only_leading_plus_minus
3998 Allow special treatment for '+', '\-', '*' in the command line (select,
3999 unselect, reverse selection) only if the command line is empty.  You
4000 don't need to quote those characters in the middle of the command line.
4001 On the other hand, you cannot use them to change selection when the
4002 command line is not empty.
4004 .I show_output_starts_shell
4005 This variable only works if you are not using the subshell support.
4006 When you use the C\-o keystroke to go back to the user screen, if this
4007 one is set, you will get a fresh shell.  Otherwise, pressing any key
4008 will bring you back to the Midnight Commander.
4010 .I timeformat_recent
4011 Change the time format used to display dates less than 6 months from
4012 now.
4013 See strftime or date man page for the format specification. If this
4014 option is absent, default timeformat is used.
4016 .I timeformat_old
4017 Change the time format used to display  dates older than 6 months from
4018 now or for dates in the future.
4019 See strftime or date man page for the format specification. If this
4020 option is absent, default timeformat is used.
4022 .I torben_fj_mode
4023 If this flag is set, then the home and end keys will work slightly
4024 different on the panels, instead of moving the selection to the first
4025 and last files in the panels, they will act as follows:
4027 The home key will: Go up to the middle line, if below it; else go to the
4028 top line unless it is already on the top line, in this case it will go
4029 to the first file in the panel.
4031 The end key has a similar behavior: Go down to the middle line, if over
4032 it; else go to the bottom line unless you already are at the bottom
4033 line, in such case it will move the selection to the last file name in
4034 the panel.
4036 .I use_file_to_guess_type
4037 If this variable is on (the default) it will spawn the file command to
4038 match the file types listed on the
4039 .\"LINK2"
4040 mc.ext file\&.
4041 .\"Extension File Edit"
4043 .I xtree_mode
4044 If this variable is on (default is off) when you browse the file system
4045 on a Tree panel, it will automatically reload the other panel with the
4046 contents of the selected directory.
4048 .I fish_directory_timeout
4049 This variable holds the lifetime of a directory cache entry in seconds. The
4050 default value is 900 seconds.
4052 .I clipboard_store
4053 This variable contains path (with options) to the external clipboard
4054 utility like 'xclip' to read text into X selection from file.
4055 For example:
4058 clipboard_store=xclip \-i
4061 .I clipboard_paste
4062 This variable contains path (with options) to the external clipboard
4063 utility like 'xclip' to print the selection to standard out.
4064 For example:
4067 clipboard_pastee=xclip \-o
4070 .I autodetect_codeset
4071 This option allows use the `enca' command to autodetect codeset of text files
4072 in internal viewer and editor. List of valid values can be obtain by the
4073 `enca \-\-list languages | cut \-d : \-f1' command. Option must be located
4074 in the [Misc] section.
4076 For example:
4079 autodetect_codeset=russian
4081 .\"NODE "Terminal databases"
4082 .SH "Terminal databases"
4083 The Midnight Commander provides a way to fix your system terminal
4084 database without requiring root privileges.  The Midnight Commander
4085 searches in the system initialization file (the mc.lib file located in
4086 the Midnight Commander library directory) and in the 
4087 ~/.config/mc/ini file for the section 
4088 "terminal:your\-terminal\-name" and then for the section
4089 "terminal:general", each line of the section contains a key symbol that
4090 you want to define, followed by an equal sign and the definition for the
4091 key.  You can use the special \\e form to represent the escape character
4092 and the ^x to represent the control\-x character.
4094 The possible key symbols are:
4097 f0 to f20     Function keys f0\-f20
4098 bs            backspace
4099 home          home key
4100 end           end key
4101 up            up arrow key
4102 down          down arrow key
4103 left          left arrow key
4104 right         right arrow key
4105 pgdn          page down key
4106 pgup          page up key
4107 insert        the insert character
4108 delete        the delete character
4109 complete      to do completion
4112 For example, to define the key insert to be the Escape + [ + O + p, you
4113 set this in the ini file:
4116 insert=\\e[Op
4120 Also now you can use
4121 .I extended learn keys.
4122 For example:
4125     ctrl\-alt\-right=\\e[[1;6C
4126     ctrl\-alt\-left=\\e[[1;6D
4130 This means that ctrl+alt+left sends a \\e[[1;6D escape sequence
4131 and therefore Midnight Commander interprets "\\e[[1;6D" as Ctrl\-Alt\-Left.
4135 .I complete
4136 key symbol represents the escape sequences used to invoke the completion
4137 process, this is invoked with Alt\-tab, but you can define other keys to do
4138 the same work (on those keyboard with tons of nice and unused keys
4139 everywhere).
4140 .SH ""
4141 .\"NODE "FILES"
4142 .SH "FILES"
4143 Full paths below may vary between installations.  They are also affected
4144 by the
4145 .BR MC_DATADIR
4146 environment variable. If it's set, its value is used instead of
4147 %prefix%/share/mc in the paths below.
4149 .I %prefix%/share/mc/mc.hlp
4151 The help file for the program.
4153 .I %prefix%/share/mc/mc.ext
4155 The default system\-wide extensions file.
4157 .I ~/.config/mc/mc.ext
4159 User's own extension, view configuration and edit configuration
4160 file.  They override the contents of the system wide files if present.
4162 .I %prefix%/share/mc/mc.ini
4164 The default system\-wide setup for the Midnight Commander, used only if
4165 the user doesn't have his own ~/.config/mc/ini file.
4167 .I %prefix%/share/mc/mc.lib
4169 Global settings for the Midnight Commander.  Settings in this file
4170 affect all users, whether they have ~/.config/mc/ini or not.  Currently, only
4171 .\"LINK2"
4172 terminal settings
4173 .\"Terminal databases"
4174 are loaded from mc.lib.
4176 .I ~/.config/mc/ini
4178 User's own setup. If this file is present then the setup is loaded
4179 from here instead of the system\-wide startup file.
4181 .I %prefix%/share/mc/mc.hint
4183 This file contains the hints displayed by the program.
4185 .I %prefix%/share/mc/mc.menu
4187 This file contains the default system\-wide applications menu.
4189 .I ~/.config/mc/menu
4191 User's own application menu. If this file is present it is used instead
4192 of the system\-wide applications menu.
4194 .I ~/.cache/mc/Tree
4196 The directory list for the directory tree and tree view features.
4198 .I ~/.local/share/mc.menu
4200 Local user\-defined menu. If this file is present, it is used instead of
4201 the home or system\-wide applications menu.
4203 To change default root directory of MC, you can use
4204 .BR MC_HOME
4205 environment variable. The value of MC_HOME must be an absolute path. If MC_HOME
4206 is unset or empty, HOME variable is used. If HOME is unset or empty, MC
4207 directories are get from GLib library.
4208 .\"SKIP_SECTION"
4209 .SH "LICENSE"
4210 This program is distributed under the terms of the GNU General Public
4211 License as published by the Free Software Foundation. See the built\-in
4212 help for details on the License and the lack of warranty.
4213 .\"NODE "AVAILABILITY"
4214 .SH "AVAILABILITY"
4215 The latest version of this program can be found at
4216 ftp://ftp.gnu.org/gnu/mc/.
4217 .\"NODE "SEE ALSO"
4218 .SH "SEE ALSO"
4219 ed(1), gpm(1), terminfo(1), view(1), sh(1), bash(1),
4220 tcsh(1), zsh(1).
4223 The Midnight Commander page on the World Wide Web:
4224         http://www.midnight\-commander.org/
4226 .\"NODE "AUTHORS"
4227 .SH "AUTHORS"
4228 Authors and contributors are listed in the AUTHORS file in the source
4229 distribution.
4230 .\"NODE "BUGS"
4231 .SH "BUGS"
4232 See the file TODO in the distribution for information on what remains to
4233 be done.
4235 If you want to report a problem with the program, please send mail to
4236 this address: mc\-devel@gnome.org.
4238 Provide a detailed description of the bug, the version of the program
4239 you are running
4240 .RI ( "mc \-V"
4241 displays this information), the operating system you are running the
4242 program on.  If the program crashes, we would appreciate a stack trace.