Ticket #3913: implement safe file overwrite.
[midnight-commander.git] / doc / man / mc.1.in
blob3303eff7e212e846b66e3277dc1e258e819ce4ae
1 .\" -*- mode: troff; coding: UTF-8 -*-
2 .\"TOPICS "Topics:"
3 .TH MC 1 "%DATE_OF_MAN_PAGE%" "MC Version %DISTR_VERSION%" "GNU Midnight Commander"
4 .\"SKIP_SECTION"
5 .SH "NAME"
6 mc \- Visual shell for Unix\-like systems.
7 .\"SKIP_SECTION"
8 .SH "USAGE"
9 .B mc
10 [\-abcCdfhPstuUVx] [\-l log] [dir1 [dir2]] [\-e [file] ...] [\-v file]
11 .\"NODE "DESCRIPTION"
12 .SH "DESCRIPTION"
13 GNU Midnight Commander is a directory browser/file manager for
14 Unix\-like operating systems.
15 .\"NODE "OPTIONS"
16 .\"DONT_SPLIT"
17 .SH "OPTIONS"
18 .TP
19 .I \-a, \-\-stickchars
20 Disable usage of graphic characters for line drawing.
21 .TP
22 .I \-b, \-\-nocolor
23 Force black and white display.
24 .TP
25 .I \-c, \-\-color
26 Force color mode, please check the section
27 .\"LINK2"
28 Colors
29 .\"Colors"
30 for more information.
31 .TP
32 .I \-C arg, \-\-colors=arg
33 Specify a different color set in the command line.  The format of arg is
34 documented in the
35 .\"LINK2"
36 Colors
37 .\"Colors"
38 section.
39 .TP
40 .I \-\-configure\-options
41 Display configure options.
42 .TP
43 .I \-d, \-\-nomouse
44 Disable mouse support.
45 .TP
46 .I \-D N, \-\-debuglevel=N
47 Save the debug level for SMB VFS. N is in 0\-10 range.
48 .TP
49 .I \-e [file], \-\-edit[=file]
50 Start the internal editor.  If the file is specified, open it on
51 startup.  See also
52 .BR "mcedit (1)" .
53 .TP
54 .I \-f, \-\-datadir
55 Display the compiled\-in search paths for Midnight Commander files.
56 .TP
57 .I \-F, \-\-datadir\-info
58 Display extended info about compiled\-in paths for
59 Midnight Commander.
60 .TP
61 .I \-g, \-\-oldmouse
62 Force a "normal tracking" mouse mode. Used when running on
63 xterm\-capable terminals (tmux/screen).
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 \-l file, \-\-ftplog=file
73 Save the ftpfs dialog with the server in file.
74 .TP
75 .I \-\-nokeymap
76 Don't load key bindings from any file, use default hardcoded keys.
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 Midnight Commander was in. Source the file
83 .B %libexecdir%/mc/mc.sh
84 (bash and zsh users) or
85 .B %libexecdir%/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, \-\-slow
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 following
94 parameters.
96 .B You can redefine the following variables:
97 .TP
98 .B lefttop
99 left\-top corner
101 .B righttop
102 right\-top corner
104 .B centertop
105 center\-top cross
107 .B centerbottom
108 center\-bottom cross
110 .B leftbottom
111 left\-bottom corner
113 .B rightbottom
114 right\-bottom corner
116 .B leftmiddle
117 left\-middle cross
119 .B rightmiddle
120 right\-middle cross
122 .B centermiddle
123 center cross
125 .B horiz
126 default horizontal line
128 .B vert
129 default vertical line
131 .B thinhoriz
132 thin horizontal line
134 .B thinvert
135 thin vertical line
137 .I \-S arg, \-\-skin=arg
138 Specify a name of skin in the command line. Technology of skins is
139 documented in the
140 .\"LINK2"
141 Skins
142 .\"Skins"
143 section.
145 .I \-t, \-\-termcap
146 Used only if the code was compiled with Slang and terminfo: it makes
147 Midnight Commander use the value of the
148 .B TERMCAP
149 variable for the terminal information instead of the information on
150 the system wide terminal database
152 .I \-u, \-\-nosubshell
153 Disable use of the concurrent shell (only makes sense if Midnight
154 Commander has been built with concurrent shell support).
156 .I \-U, \-\-subshell
157 Enable use of the concurrent shell support (only makes sense if the
158 Midnight Commander was built with the subshell support set as an
159 optional feature).
161 .I \-v file, \-\-view=file
162 Start the internal viewer to view the specified file.  See also
163 .BR "mcview (1)" .
165 .I \-V, \-\-version
166 Display the version of the program.
168 .I \-x, \-\-xterm
169 Force xterm mode.  Used when running on xterm\-capable terminals (two
170 screen modes, and able to send mouse escape sequences).
172 .I \-X, \-\-no\-x11
173 Do not use X11 to get the state of modifiers Alt, Ctrl, Shift
175 If both paths are specified, the first path name is the directory to show
176 in the active panel; the second path name is the directory to be shown in
177 the other panel.
179 If one path is specified, the path name is the directory to show
180 in the active panel; value of "other_dir" from panels.ini is the directory
181 to be shown in the passive panel.
183 If no paths are specified, current directory is shown in the active panel;
184 value of "other_dir" from panels.ini is the directory to be shown in
185 the passive panel.
186 .\"NODE "Overview"
187 .SH "Overview"
188 The screen of Midnight Commander is divided into four parts.
189 Almost all of the screen space is taken up by two directory panels.
190 By default, the second line from the bottom of the screen is the
191 shell command line, and the bottom line shows the function key labels.
192 The topmost line is the
193 .\"LINK2"
194 menu bar line\&.
195 .\"Menu Bar"
196 The menu bar line may not be visible, but appears if you click the
197 topmost line with the mouse or press the F9 key.
199 Midnight Commander provides a view of two directories at the same
200 time. One of the panels is the current panel (a selection bar is in
201 the current panel). Almost all operations take place on the current
202 panel. Some file operations like Rename and Copy by default use the
203 directory of the unselected panel as a destination (don't worry, they
204 always ask you for confirmation first). For more information, see the
205 sections on the
206 .\"LINK2"
207 Directory Panels\&,
208 .\"Directory Panels"
210 .\"LINK2"
211 Left and Right Menus
212 .\"Left and Right Menus"
213 and the
214 .\"LINK2"
215 File Menu\&.
216 .\"File Menu"
218 You can execute system commands from Midnight Commander by simply
219 typing them. Everything you type will appear on the shell command line,
220 and when you press Enter, Midnight Commander will execute the
221 command line you typed; read the
222 .\"LINK2"
223 Shell Command Line
224 .\"Shell Command Line"
226 .\"LINK2"
227 Input Line Keys
228 .\"Input Line Keys"
229 sections to learn more about the command line.
230 .\"NODE "Mouse Support"
231 .SH "Mouse Support"
232 Midnight Commander comes with mouse support. It is activated
233 whenever you are running on an
234 .B xterm(1)
235 terminal (it even works if you take a telnet, ssh or rlogin connection to
236 another machine from the xterm) or if you are running on a Linux
237 console and have the
238 .B gpm
239 mouse server running.
241 When you left click on a file in the directory panels, that file is
242 selected; if you click with the right button, the file is marked (or
243 unmarked, depending on the previous state).
245 Double\-clicking on a file will try to execute the command if it is
246 an executable program; and if the
247 .\"LINK2"
248 extension file
249 .\"Edit Extension File"
250 has a program specified for the file's extension, the specified
251 program is executed.
253 Also, it is possible to execute the commands assigned to the function
254 key labels by clicking on them.
256 The default auto repeat rate for the mouse buttons is 400
257 milliseconds. This may be changed to other values by editing the
258 .\"LINK2"
259 \&~/.config/mc/ini
260 .\"Save Setup"
261 file and changing the
262 .I mouse_repeat_rate
263 parameter.
265 If you are running Midnight Commander with the mouse support, you
266 can get the default mouse behavior (cutting and pasting text) by holding
267 down the Shift key.
268 .SH ""
269 .\"NODE "Keys"
270 .SH "Keys"
271 Some commands in Midnight Commander involve the use of the
272 .I Control
273 (sometimes labeled CTRL or CTL) and the
274 .I Meta
275 (sometimes labeled ALT or even Compose) keys. In this manual we will
276 use the following abbreviations:
278 .B C\-<chr>
279 means hold the Control key while typing the character <chr>.
280 Thus C\-f would be: hold the Control key and type f.
282 .B Alt\-<chr>
283 means hold the Meta or Alt key down while typing <chr>.
284 If there is no Meta or Alt key, type
285 .IR ESC ,
286 release it, then type the character <chr>.
288 .B S\-<chr>
289 means hold the Shift key down while typing <chr>.
291 All input lines in Midnight Commander use an approximation to
292 the GNU Emacs editor's key bindings (default).
294 You may redefine key bindings. See
295 .\"LINK2"
296 .I redefine hotkey bindings
297 .\"Keys_redefine"
299 for more info. All other key bindings (described in this manual) are relative
300 to default behavior.
303 There are many sections which tell about the keys. The following are
304 the most important.
307 .\"LINK2"
308 File Menu
309 .\"File Menu"
310 section documents the keyboard shortcuts for the commands appearing in
311 the File menu. This section includes the function keys. Most of these
312 commands perform some action, usually on the selected file or the
313 tagged files.
316 .\"LINK2"
317 Directory Panels
318 .\"Directory Panels"
319 section documents the keys which select a file or tag files as a
320 target for a later action (the action is usually one from the file
321 menu).
324 .\"LINK2"
325 Shell Command Line
326 .\"Shell Command Line"
327 section list the keys which are used for entering and editing command
328 lines. Most of these copy file names and such from the directory
329 panels to the command line (to avoid excessive typing) or access the
330 command line history.
332 .\"LINK2"
333 Input Line Keys
334 .\"Input Line Keys"
335 are used for editing input lines. This means both the command line and
336 the input lines in the query dialogs.
338 .\"NODE "  Keys_redefine"
339 .SH "  Redefine hotkey bindings"
340 Hotkey bindings may be read from external file (keymap\-file).
341 Initially, Midnight Commander creates key bindings using keymap defined
342 in the source code. Then, two files
343 .B %prefix%/share/mc/mc.keymap
345 .B %sysconfdir%/mc/mc.keymap
346 are loaded always, sequentially reassigned key bindings defined earlier.
347 User\-defined keymap\-file is searched on the following algorithm (to the first one found):
350 1) command line option
351 .B \-K <keymap>
353 .B \-\-keymap=<keymap>
355 2) Environment variable
356 .B MC_KEYMAP
358 3) Parameter
359 .B keymap
360 in section
361 .B [Midnight\-Commander]
362 of config file.
364 4) File
365 .B ~/.config/mc/mc.keymap
368 Command line option, environment variable and parameter in config file may
369 contain the absolute path to the keymap\-file (with the extension \.keymap
370 or without it). Search of keymap\-file will occur in (to the first one found):
374 .B ~/.config/mc
377 .B %sysconfdir%/mc/
380 .B %prefix%/share/mc/
382 .\"NODE "  Miscellaneous Keys"
383 .SH "  Miscellaneous Keys"
384 Here are some keys which don't fall into any of the other categories:
386 .B Enter
387 if there is some text in the command line (the one at the bottom of
388 the panels), then that command is executed. If there is no text in the
389 command line then if the selection bar is over a directory the
390 Midnight Commander does a
391 .B chdir(2)
392 to the selected directory and reloads the information on the panel;
393 if the selection is an executable file then it is executed. Finally,
394 if the extension of the selected file name matches one of the
395 extensions in the
396 .\"LINK2"
397 extensions file
398 .\"Edit Extension File"
399 then the corresponding command is executed.
401 .B C\-l
402 repaint all the information in Midnight Commander.
404 .B C\-x c
405 run the
406 .\"LINK2"
407 Chmod
408 .\"Chmod"
409 command on a file or on the tagged files.
411 .B C\-x o
412 run the
413 .\"LINK2"
414 Chown
415 .\"Chown"
416 command on the current file or on the tagged files.
418 .B C\-x l
419 run the hard link command.
421 .B C\-x s
422 run the absolute symbolic link command.
424 .B C\-x v
425 run the relative symbolic link command. See the
426 .\"LINK2"
427 File Menu
428 .\"File Menu"
429 section for more information about symbolic links.
431 .B C\-x i
432 set the other panel display mode to information.
434 .B C\-x q
435 set the other panel display mode to quick view.
437 .B C\-x !
438 execute the
439 .\"LINK2"
440 External panelize
441 .\"External panelize"
442 command.
444 .B C\-x h
445 run the
446 .\"LINK2"
447 add directory to hotlist
448 .\"Hotlist"
449 command.
451 .B Alt\-!
452 executes the Filtered view command, described in the
453 .\"LINK2"
454 view command\&.
455 .\"Internal File Viewer"
457 .B Alt\-?
458 executes the
459 .\"LINK2"
460 Find file
461 .\"Find File"
462 command.
464 .B Alt\-c
465 pops up the
466 .\"LINK2"
467 quick cd
468 .\"Quick cd"
469 dialog.
471 .B C\-o
472 when the program is being run in the Linux or FreeBSD console or under
473 an xterm, it will show you the output of the previous command.  When ran
474 on the Linux console, Midnight Commander uses an external program
475 (cons.saver) to handle saving and restoring of information on the
476 screen.
478 When the subshell support is compiled in, you can type C\-o at any time
479 and you will be taken back to Midnight Commander's main screen, to
480 return to your application just type C\-o.  If you have an application
481 suspended by using this trick, you won't be able to execute other
482 programs from Midnight Commander until you terminate the suspended
483 application.
484 .\"NODE "  Directory Panels"
485 .SH "  Directory Panels"
486 This section lists the keys which operate on the directory panels. If
487 you want to know how to change the appearance of the panels take a
488 look at the section on
489 .\"LINK2"
490 Left and Right Menus\&.
491 .\"Left and Right Menus"
493 .B Tab, C\-i
494 change the current panel. The old other panel becomes the new current
495 panel and the old current panel becomes the new other panel. The
496 selection bar moves from the old current panel to the new current
497 panel.
499 .B Insert, C\-t
500 to tag files you may use the Insert key (the kich1 terminfo sequence).
501 To untag files, just retag a tagged file.
503 .B M\-e
504 to change charset of panel you may use M\-e (Alt\-e).
505 Recoding is made from selected codepage into system codepage. To
506 cancel the recoding, select "No translation" in the dialog of encodings.
508 .B Alt\-g, Alt\-r, Alt\-j
509 used to select the top file in a panel, the middle file and the bottom one,
510 respectively.
512 .B Alt\-t
513 toggle the current display listing to show the next display listing
514 format.
515 With this it is possible to quickly switch to brief listing, long
516 listing, user defined listing format, and back to the default.
518 .B C\-\\\\ (control\-backslash)
519 show the
520 .\"LINK2"
521 directory hotlist
522 .\"Hotlist"
523 and change to the selected directory.
525 .B + \ (plus)
526 this is used to select (tag) a group of files. Midnight Commander
527 will prompt for a selection options. When
528 .I Files only
529 checkbox is on, only files will be selected.  If
530 .I Files only
531 is off, as files as directories will be selected.
532 When
533 .I Shell Patterns
534 checkbox is on, the regular expression is much like the filename globbing
535 in the shell (* standing for zero or more characters and ? standing
536 for one character). If
537 .I Shell Patterns
538 is off, then the tagging of files is done with normal regular
539 expressions (see ed (1)). When
540 .I Case sensitive
541 checkbox is on, the selection will be case sensitive characters.
543 .I Case sensitive
544 is off, the case will be ignored.
546 .B \\\\ (backslash)
547 use the "\\" key to unselect a group of files. This is the opposite of
548 the Plus key.
550 .B up\-key, C\-p
551 move the selection bar to the previous entry in the panel.
553 .B down\-key, C\-n
554 move the selection bar to the next entry in the panel.
556 .B home, a1, Alt\-<
557 move the selection bar to the first entry in the panel.
559 .B end, c1, Alt\->
560 move the selection bar to the last entry in the panel.
562 .B next\-page, C\-v
563 move the selection bar one page down.
565 .B prev\-page, Alt\-v
566 move the selection bar one page up.
568 .B Alt\-o
569 If the currently selected file is a directory, load that directory on
570 the other panel and moves the selection to the next file. If the
571 currently selected file is not a directory, load the parent directory
572 on the other panel and moves the selection to the next file.
574 .B Alt\-i
575 make the current directory of the current panel also the current
576 directory of the other panel.  Put the other panel to the listing mode
577 if needed.  If the current panel is panelized, the other panel doesn't
578 become panelized.
580 .B C\-PageUp, C\-PageDown
581 only when supported by the terminal: change to ".." and to the currently
582 selected directory respectively.
584 .B Alt\-y
585 moves to the previous directory in the history, equivalent to clicking
587 .I <
588 with the mouse.
590 .B Alt\-u
591 moves to the next directory in the history, equivalent to clicking the
592 .I >
593 with the mouse.
595 .B Alt\-Shift\-h, Alt\-H
596 displays the directory history, equivalent to depressing the 'v' with
597 the mouse.
598 .\"NODE "  Quick search"
599 .SH "  Quick search"
600 The Quick search mode allows you to perform fast file search in file panel.
601 Press
602 .I C\-s
604 .I Alt\-s
605 to start a filename search in the directory listing.
607 When the search is active, the user input will be added to the search string
608 instead of the command line. If the
609 .I Show mini\-status
610 option is enabled the search string is shown on the mini\-status
611 line. When typing, the selection bar will move to the next file
612 starting with the typed letters. The
613 .I Backspace
615 .I DEL
616 keys can be used to correct typing mistakes. If C\-s is pressed
617 again, the next match is searched for.
619 If quick search is started with double pressing of C\-s, the previous quick
620 search pattern will be used for current search.
622 Besides the filename characters, you can also use wildcard
623 characters '*' and '?'.
624 .\"NODE "  Shell Command Line"
625 .SH "  Shell Command Line"
626 This section lists keys which are useful to avoid excessive typing when
627 entering shell commands.
629 .B Alt\-Enter
630 copy the currently selected file name to the command line.
632 .B C\-Enter
633 same a Alt\-Enter.  May not work on remote systems and some terminals.
635 .B C\-Shift\-Enter
636 copy the full path name of the currently selected file to the command
637 line.  May not work on remote systems and some terminals.
639 .B Alt\-Tab
640 does the filename, command, variable, username and hostname
641 .\"LINK2"
642 completion
643 .\"Completion"
644 for you.
646 .B C\-x t, C\-x C\-t
647 copy the tagged files (or if there are no tagged files, the selected
648 file) of the current panel (C\-x t) or of the other panel (C\-x C\-t) to
649 the command line.
651 .B C\-x p, C\-x C\-p
652 the first key sequence copies the current path name to the command
653 line, and the second one copies the unselected panel's path name to
654 the command line.
656 .B C\-q
657 the quote command can be used to insert characters that are otherwise
658 interpreted by Midnight Commander (like the '+' symbol)
660 .B Alt\-p, Alt\-n
661 use these keys to browse through the command history. Alt\-p takes you
662 to the last entry, Alt\-n takes you to the next one.
664 .B Alt\-h
665 displays the history for the current input line.
666 .\"NODE "  General Movement Keys"
667 .SH "  General Movement Keys"
668 The help viewer, the file viewer and the directory tree use common
669 code to handle moving. Therefore they accept exactly the same
670 keys. Each of them also accepts some keys of its own.
672 Other parts of Midnight Commander use some of the same movement
673 keys, so this section may be of use for those parts too.
675 .B Up, C\-p
676 moves one line backward.
678 .B Down, C\-n
679 moves one line forward.
681 .B Prev Page, Page Up, Alt\-v
682 moves one page up.
684 .B Next Page, Page Down, C\-v
685 moves one page down.
687 .B Home, A1
688 moves to the beginning.
690 .B End, C1
691 move to the end.
693 The help viewer and the file viewer accept the following keys in
694 addition the to ones mentioned above:
696 .B b, C\-b, C\-h, Backspace, Delete
697 moves one page up.
699 .B Space bar
700 moves one page down.
702 .B u, d
703 moves one half of a page up or down.
705 .B g, G
706 moves to the beginning or to the end.
707 .\"NODE "  Input Line Keys"
708 .SH "  Input Line Keys"
709 The input lines (they are used for the
710 .\"LINK2"
711 command line
712 .\"Shell Command Line"
713 and for the query dialogs in the program) accept these keys:
715 .B C\-a
716 puts the cursor at the beginning of line.
718 .B C\-e
719 puts the cursor at the end of the line.
721 .B C\-b, move\-left
722 move the cursor one position left.
724 .B C\-f, move\-right
725 move the cursor one position right.
727 .B Alt\-f
728 moves one word forward.
730 .B Alt\-b
731 moves one word backward.
733 .B C\-h, Backspace
734 delete the previous character.
736 .B C\-d, Delete
737 delete the character in the point (over the cursor).
739 .B C\-@
740 sets the mark for cutting.
742 .B C\-w
743 copies the text between the cursor and the mark to a kill buffer and
744 removes the text from the input line.
746 .B Alt\-w
747 copies the text between the cursor and the mark to a kill buffer.
749 .B C\-y
750 yanks back the contents of the kill buffer.
752 .B C\-k
753 kills the text from the cursor to the end of the line.
755 .B Alt\-p, Alt\-n
756 Use these keys to browse through the command history. Alt\-p takes you
757 to the last entry, Alt\-n takes you to the next one.
759 .B Alt\-C\-h, Alt\-Backspace
760 delete one word backward.
762 .B Alt\-Tab
763 does the filename, command, variable, username and hostname
764 .\"LINK2"
765 completion
766 .\"Completion"
767 for you.
768 .SH ""
769 .\"NODE "Menu Bar"
770 .SH "Menu Bar"
771 The menu bar pops up when you press F9 or click the mouse on the top
772 row of the screen. The menu bar has five menus: "Left", "File",
773 "Command", "Options" and "Right".
776 .\"LINK2"
777 Left and Right Menus
778 .\"Left and Right Menus"
779 allow you to modify the appearance of the left and right directory
780 panels.
783 .\"LINK2"
784 File Menu
785 .\"File Menu"
786 lists the actions you can perform on the currently selected file or
787 the tagged files.
790 .\"LINK2"
791 Command Menu
792 .\"Command Menu"
793 lists the actions which are more general and bear no relation to the
794 currently selected file or the tagged files.
797 .\"LINK2"
798 Options Menu
799 .\"Options Menu"
800 lists the actions which allow you to customize Midnight Commander.
801 .\"NODE "  Left and Right Menus"
802 .SH "  Left and Right (Above and Below) Menus"
803 The outlook of the directory panels can be changed from the
804 .B Left
806 .B Right
807 menus (they are named
808 .B Above
810 .B Below
811 when the horizontal panel split is chosen from the
812 .\"LINK2"
813 Layout
814 .\"Layout"
815 options dialog).
816 .\"NODE "    Listing Format..."
817 .SH "    Listing Format..."
818 The listing mode view is used to display a listing of files, there are
819 four different listing formats available:
820 .BR Full ,
821 .BR Brief ,
822 .B Long
824 .BR User .
825 The full directory view shows the file name, the size of the file and
826 the modification time.
828 The brief view shows only the file name and it has from 1 up to 9 columns
829 (therefore showing more files unlike other views). The long view
830 is similar to the output of
831 .B "ls \-l"
832 command. The long view takes the whole screen width.
834 If you choose the "User" display format, then you have to specify
835 the display format.
837 The user display format must start with a panel size specifier.  This
838 may be "half" or "full", and they specify a half screen panel and a
839 full screen panel respectively.
841 After the panel size, you may specify how many listings to fit in the
842 panel, side\-by\-side (in other words: how many times to repeat the
843 fields horizontally). This defaults to 1. You may change this by adding a
844 number from 1 to 9 to the format string.
846 After this you add the name of the fields with an optional size
847 specifier.  This are the available fields you may display:
849 .B name
850 displays the file name.
852 .B size
853 displays the file size.
855 .B bsize
856 is an alternative form of the
857 .B size
858 format. It displays the size of the files and for directories it just
859 shows SUB\-DIR or UP\-\-DIR.
861 .B type
862 displays a one character wide type field.  This character is similar to
863 what is displayed by ls with the \-F flag \-
864 .B *
865 for executable files,
866 .B /
867 for directories,
868 .B @
869 for links,
870 .B =
871 for sockets,
872 .B \-
873 for character devices,
874 .B +
875 for block devices,
876 .B |
877 for pipes,
878 .B ~
879 for symbolic links to directories and
880 .B !
881 for stale symlinks (links that point nowhere).
883 .B mark
884 an asterisk if the file is tagged, a space if it's not.
886 .B mtime
887 file's last modification time.
889 .B atime
890 file's last access time.
892 .B ctime
893 file's status change time.
895 .B perm
896 a string representing the current permission bits of the file.
898 .B mode
899 an octal value with the current permission bits of the file.
901 .B nlink
902 the number of links to the file.
904 .B ngid
905 the GID (numeric).
907 .B nuid
908 the UID (numeric).
910 .B owner
911 the owner of the file.
913 .B group
914 the group of the file.
916 .B inode
917 the inode of the file.
919 Also you can use following keywords to define the panel layout:
921 .B space
922 a space in the display format.
924 .B |
925 add a vertical line to the display format.
927 To force one field to a fixed size (a size specifier), you just add
928 .B :
929 followed by the number of characters you want the field to have.  If the
930 number is followed by the symbol
931 .BR + ,
932 then the size specifies the minimal field size \- if the program finds
933 out that there is more space on the screen, it will then expand that
934 field.
936 For example, the
937 .B Full
938 display corresponds to this format:
940 half type name | size | mtime
942 And the
943 .B Long
944 display corresponds to this format:
946 full perm space nlink space owner space group space size space mtime
947 space name
949 This is a nice user display format:
951 half name | size:7 | type mode:3
953 Panels may also be set to the following modes:
955 .B "Info"
956 The info view display information related to the currently
957 selected file and if possible information about the current file
958 system.
960 .B "Tree"
961 The tree view is quite similar to the
962 .\"LINK2"
963 directory tree
964 .\"Directory Tree"
965 feature. See the section about it for more information.
967 .B "Quick View"
968 In this mode, the panel will switch to a reduced
969 .\"LINK2"
970 viewer
971 .\"Internal File Viewer"
972 that displays the contents of the currently selected file, if you
973 select the panel (with the tab key or the mouse), you will have access
974 to the usual viewer commands.
975 .\"NODE "    Sort Order..."
976 .SH "    Sort Order..."
977 The eight sort orders are by name, by extension, by modification time,
978 by access time, and by inode information modification time, by size,
979 by inode and unsorted.  In the Sort order dialog box you can choose
980 the sort order and you may also specify if you want to sort in reverse
981 order by checking the reverse box.
983 By default directories are sorted before files but this can be changed
984 from the
985 .\"LINK2"
986 Panel options
987 .\"Panel options"
988 menu (option
989 .BR "Mix all files" ).
990 .\"NODE "    Filter..."
991 .SH "    Filter..."
992 The filter command allows you to specify a shell pattern (for example
993 .BR "*.tar.gz" )
994 which the files must match to be shown. Regardless
995 of the filter pattern, the directories and the links to directories
996 are always shown in the directory panel.
997 .\"NODE "    Reread"
998 .SH "    Reread"
999 The reread command reload the list of files in the directory. It is
1000 useful if other processes have created or removed files.
1001 .\"NODE "  File Menu"
1002 .SH "  File Menu"
1003 Midnight Commander uses the F1 \- F10 keys as keyboard shortcuts
1004 for commands appearing in the file menu.  The escape sequences for the
1005 function keys are terminfo capabilities kf1 trough kf10.  On terminals
1006 without function key support, you can achieve the same functionality by
1007 pressing the ESC key and then a number in the range 1 through 9 and 0
1008 (corresponding to F1 to F9 and F10 respectively).
1010 The File menu has the following commands (keyboard shortcuts in parentheses):
1012 .B Help (F1)
1014 Invokes the built\-in hypertext help viewer. Inside the
1015 .\"LINK2"
1016 help viewer\&,
1017 .\"Contents"
1018 you can use the Tab key to select the next link and the Enter key to
1019 follow that link. The keys Space and Backspace are used to move
1020 forward and backward in a help page. Press F1 again to get the full
1021 list of accepted keys.
1023 .B Menu (F2)
1025 Invoke the
1026 .\"LINK2"
1027 user menu\&.
1028 .\"Edit Menu File"
1029 The user menu provides an easy way to provide users with a menu and
1030 add extra features to Midnight Commander.
1032 .B View (F3, F13)
1034 View the currently selected file. By default this invokes the
1035 .\"LINK2"
1036 Internal File Viewer
1037 .\"Internal File Viewer"
1038 but if the option "Use internal view" is off, it invokes an external
1039 file viewer specified by the
1040 .B VIEWER
1041 environment variable.  If
1042 .B VIEWER
1043 is undefined, the
1044 .B PAGER
1045 environment variable is tried.  If
1046 .B PAGER
1047 is also undefined, the "view" command is invoked.  If you use F13
1048 instead, the viewer will be invoked without doing any formatting or
1049 preprocessing to the file.
1052 .\"LINK2"
1053 parameters for external viewer
1054 .\"Parameters for external editor or viewer"
1055 for explain how you may specify an extended command line options
1056 for external viewers.
1058 .B Filtered View (Alt\-!)
1060 This command prompts for a command
1061 and its arguments (the argument defaults to the currently selected
1062 file name), the output from such command is shown in the internal file
1063 viewer.
1065 .B Edit (F4, F14)
1067 Press F4 to edit the highlighted file.  Press F14 (usually F14)
1068 to start the editor with a new, empty file.
1069 Currently they invoke the
1070 .B vi
1071 editor, or the editor specified in the
1072 .B EDITOR
1073 environment variable, or the
1074 .\"LINK2"
1075 Internal File Editor
1076 .\"Internal File Editor"
1077 if the use_internal_edit option is on.
1080 .\"LINK2"
1081 parameters for external editor
1082 .\"Parameters for external editor or viewer"
1083 for explain how you may specify an extended command line options
1084 for external editors.
1086 .B Copy (F5, F15)
1088 Press F5 to pop up an input dialog to copy the currently selected file (or
1089 the tagged files, if there is at least one file tagged) to the
1090 directory/filename you specify in the input dialog. The destination
1091 defaults to the directory in the non\-selected panel. Space for destination
1092 file may be preallocated relative to preallocate_space configure option.
1093 During this process, you can press C\-c or ESC to abort the operation.
1094 For details about source mask (which will be usually either * or ^\\(.*\\)$
1095 depending on setting of Use shell patterns) and possible wildcards in the
1096 destination see
1097 .\"LINK2"
1098 Mask copy/rename\&.
1099 .\"Mask Copy/Rename"
1101 F15 (usually F15) is similar, but defaults to the directory in the
1102 selected panel. It always operates on the selected file, regardless of
1103 any tagged files.
1105 On some systems, it is possible to do the copy in the background by
1106 clicking on the background button (or pressing Alt\-b in the dialog
1107 box).  The
1108 .\"LINK2"
1109 Background Jobs
1110 .\"Background jobs"
1111 is used to control the background process.
1113 .B Link (C\-x l)
1115 Create a hard link to the current file.
1117 .B Absolute symlink (C\-x s)
1119 Create a absolute symbolic link to the current file.
1121 .B Relative symLink (C\-x v)
1123 Create a relative symbolic link to the current file.
1125 To those of you who don't know what links are: creating a link to a file
1126 is a bit like copying the file, but both the source filename and the destination
1127 filename represent the same file image. For example, if you edit one of these
1128 files, all changes you make will appear in both files. Some people call
1129 links aliases or shortcuts.
1131 A hard link appears as a real file. After making it, there is no way of
1132 telling which one is the original and which is the link. If you delete
1133 either one of them the other one is still intact. It is very difficult
1134 to notice that the files represent the same image. Use hard links when
1135 you don't even want to know.
1137 A symbolic link is a reference to the name of the original file. If
1138 the original file is deleted the symbolic link is useless. It is quite
1139 easy to notice that the files represent the same image. Midnight
1140 Commander shows an "@"\-sign in front of the file name if it is a
1141 symbolic link to somewhere (except to directory, where it shows a tilde (~)).
1142 The original file which the link points to is shown on mini\-status line if the
1143 .I "Show mini\-status"
1144 option is enabled. Use symbolic links when you want to avoid the
1145 confusion that can be caused by hard links.
1147 When you press "C\-x s" Midnight Commander will automatically fill in the
1148 complete path+filename of the original file and suggest a name for the link.
1149 You can change either one.
1151 Sometimes you may want to change the absolute path of the original into
1152 a relative path. An absolute path starts from the root directory:
1154 .I /home/frodo/mc/mc \-> /home/frodo/new/mc
1156 A relative link describes the original file's location starting from the
1157 location of the link itself:
1159 .I /home/frodo/mc/mc \-> ../new/mc
1161 You can force Midnight Commander to suggest a relative path by pressing
1162 "C\-x v" instead of "C\-x s".
1164 .B Rename/Move (F6, F16)
1166 Press F6 to pop up an input dialog to copy the currently selected file (or
1167 the tagged files, if there is at least one file tagged) to the
1168 directory/filename you specify in the input dialog.  The destination
1169 defaults to the directory in the non\-selected panel. For more details
1170 look at Copy (F5) operation above, most of the things are quite similar.
1172 F16 (usually F16) is similar, but defaults to the directory in the
1173 selected panel. It always operates on the selected file, regardless of
1174 any tagged files.
1176 On some systems, it is possible to do the copy in the background by
1177 clicking on the background button (or pressing Alt\-b in the dialog
1178 box).  The
1179 .\"LINK2"
1180 Background Jobs
1181 .\"Background jobs"
1182 is used to control the background process.
1184 .B Mkdir (F7)
1186 Pop up an input dialog and creates the directory specified.
1188 .B Delete (F8)
1190 Delete the currently selected file or the tagged files in the
1191 currently selected panel. During the process, you can press C\-c or
1192 ESC to abort the operation.
1194 .B Quick cd (Alt\-c)
1195 Use the
1196 .\"LINK2"
1197 quick cd
1198 .\"Quick cd"
1199 command if you have full command line and want to cd somewhere.
1201 .B Select group (+)
1203 This is used to select (tag) a group of files. Midnight Commander
1204 will prompt for a selection options. When
1205 .I Files only
1206 checkbox is on, only files will be selected.  If
1207 .I Files only
1208 is off, as files as directories will be selected.
1209 When
1210 .I Shell Patterns
1211 checkbox is on, the regular expression is much like the filename globbing
1212 in the shell (* standing for zero or more characters and ?  standing
1213 for one character). If
1214 .I Shell Patterns
1215 is off, then the tagging of files is done with normal regular
1216 expressions (see ed (1)). When
1217 .I Case sensitive
1218 checkbox is on, the selection will be case sensitive characters.
1220 .I Case sensitive
1221 is off, the case will be ignored.
1223 .B Unselect group (\\\\)
1225 Used to unselect a group of files. This is the opposite of the
1226 .I "Select group"
1227 command.
1229 .B Quit (F10, Shift\-F10)
1231 Terminate Midnight Commander. Shift\-F10 is used when you want to
1232 quit and you are using the shell wrapper.  Shift\-F10 will not take you
1233 to the last directory you visited with Midnight Commander, instead
1234 it will stay at the directory where you started Midnight Commander.
1235 .\"NODE "    Quick cd"
1236 .SH "    Quick cd"
1237 This command is useful if you have a full command line and want to
1238 .\"LINK2"
1240 .\"The cd internal command"
1241 somewhere without having to yank and paste the command line. This command
1242 pops up a small dialog, where you enter everything you would enter after
1243 .B cd
1244 on the command line and then you press enter. This features all the things
1245 that are already in the
1246 .\"LINK2"
1247 internal cd command\&.
1248 .\"The cd internal command"
1249 .\"NODE "  Command Menu"
1250 .SH "  Command Menu"
1252 .\"LINK2"
1253 Directory tree
1254 .\"Directory Tree"
1255 command shows a tree figure of the directories.
1258 .\"LINK2"
1259 "Find file"
1260 .\"Find File"
1261 command allows you to search for a specific file.
1263 The "Swap panels" command swaps the contents of the two directory panels.
1265 The "Switch panels on/off" command shows the output of the last shell command.
1266 This works only on xterm and on Linux and FreeBSD console.
1268 The "Compare directories" command compares the directory
1269 panels with each other. You can then use the Copy (F5) command to make
1270 the panels identical. There are three compare methods. The quick method
1271 compares only file size and file date. The thorough method makes a
1272 full byte\-by\-byte compare. The thorough method is not available if the
1273 machine does not support the mmap(2) system call.  The size\-only
1274 compare method just compares the file sizes and does not check the
1275 contents or the date times, it just checks the file size.
1278 .\"LINK2"
1279 "External panelize"
1280 .\"External panelize"
1281 allows you to execute an external program, and make the output of that
1282 program the contents of the current panel.
1284 The "Command history" command shows a list of typed commands. The
1285 selected command is copied to the command line. The command history
1286 can also be accessed by typing Alt\-p or Alt\-n.
1289 .\"LINK2"
1290 "Directory hotlist"
1291 .\"Hotlist"
1292 command makes changing of the current directory to often used directories
1293 faster.
1296 .\"LINK2"
1297 "Screen list"
1298 .\"Screen selector"
1299 command shows a dialog window with the list of currently running
1300 internal editors, viewers and other MC modules that support this mode.
1303 .\"LINK2"
1304 "Edit extension file"
1305 .\"Edit Extension File"
1306 command allows you to specify programs to executed when you try to
1307 execute, view, edit and do a bunch of other thing on files
1308 with certain extensions (filename endings).
1311 .\"LINK2"
1312 "Edit Menu File"
1313 .\"Edit Menu File"
1314 command may be used for editing the user menu (which appears by
1315 pressing F2).
1316 .\"NODE "    Directory Tree"
1317 .SH "    Directory Tree"
1318 The Directory Tree command shows a tree figure of the directories. You
1319 can select a directory from the figure and Midnight Commander will
1320 change to that directory.
1322 There are two ways to invoke the tree. The real directory tree command
1323 is available from Commands menu. The other way is to select tree view
1324 from the Left or Right menu.
1326 To get rid of long delays, Midnight Commander creates the tree
1327 figure by scanning only a small subset of all the directories. If the
1328 directory which you want to see is missing, move to its parent
1329 directory and press C\-r (or F2).
1331 You can use the following keys:
1333 .\"LINK2"
1334 General movement keys
1335 .\"General Movement Keys"
1336 are accepted.
1338 .B Enter.
1339 In the directory tree, exits the directory tree and changes to this
1340 directory in the current panel. In the tree view, changes to this
1341 directory in the other panel and stays in tree view mode in the
1342 current panel.
1344 .B C\-r, F2 (Rescan).
1345 Rescan this directory. Use this when the tree figure is out of date:
1346 it is missing subdirectories or shows some subdirectories which don't
1347 exist any more.
1349 .B F3 (Forget).
1350 Delete this directory from the tree figure. Use this to remove clutter
1351 from the figure. If you want the directory back to the tree figure
1352 press F2 in its parent directory.
1354 .B F4 (Static/Dynamic).
1355 Toggle between the dynamic navigation mode (default) and the static
1356 navigation mode.
1358 In the static navigation mode you can use the Up and Down keys to
1359 select a directory. All known directories are shown.
1361 In the dynamic navigation mode you can use the Up and Down keys to
1362 select a sibling directory, the Left key to move to the parent
1363 directory, and the Right key to move to a child directory. Only the
1364 parent, sibling and children directories are shown, others are left
1365 out. The tree figure changes dynamically as you traverse.
1367 .B F5 (Copy).
1368 Copy the directory.
1370 .B F6 (RenMov).
1371 Move the directory.
1373 .B F7 (Mkdir).
1374 Make a new directory below this directory.
1376 .B F8 (Delete).
1377 Delete this directory from the file system.
1379 .B C\-s, Alt\-s.
1380 Search the next directory matching the search string. If there is
1381 no such directory these keys will move one line down.
1383 .B C\-h, Backspace.
1384 Delete the last character of the search string.
1386 .B Any other character.
1387 Add the character to the search string and move to the next directory
1388 which starts with these characters. In the tree view you must first
1389 activate the search mode by pressing C\-s. The search string is shown
1390 in the mini status line.
1392 The following actions are available only in the directory tree. They
1393 aren't supported in the tree view.
1395 .B F1 (Help).
1396 Invoke the help viewer and show this section.
1398 .B Esc, F10.
1399 Exit the directory tree. Do not change the directory.
1401 The mouse is supported. A double\-click behaves like Enter. See
1402 also the section on
1403 .\"LINK2"
1404 mouse support\&.
1405 .\"Mouse Support"
1406 .\"NODE "    Find File"
1407 .SH "    Find File"
1408 The Find File feature first asks for the start directory for the
1409 search and the filename to be searched for. By pressing the Tree
1410 button you can select the start directory from the
1411 .\"LINK2"
1412 directory tree
1413 .\"Directory Tree"
1414 figure.
1416 The "File name" input field contains a filename pattern to be searched
1417 for. It is interpreted as a shell pattern or as a regular expression
1418 depending on the state of the "Using shell patterns" checkbox. An empty
1419 value is valid and matches any file name.
1421 The "Content" input field contains a string to search for within the
1422 files. Leave this field empty to disable searching file contents.
1424 Option "Whole words" allows select only those files containing matches that
1425 form whole words. Like grep \-w.
1427 You can start the search by pressing the OK button.
1428 During the search you can stop from the Stop button and continue from
1429 the Start button.
1431 You can browse the filelist with the up and down arrow keys. The Chdir
1432 button will change to the directory of the currently selected
1433 file. The Again button will ask for the parameters for a new
1434 search. The Quit button quits the search operation. The Panelize
1435 button will place the found files to the current directory panel so
1436 that you can do additional operations on them (view, copy, move,
1437 delete and so on). To return to the normal file listing, change directory
1438 to "..".
1440 The 'Enable ignore directories' checkbox and input field below it
1441 allow one to set up the list of directories that should be skip during the search
1442 files (for example, you may want to avoid searches on a CD\-ROM or on a NFS
1443 directory that is mounted across a slow link). List components must be separated
1444 with a colon, here is an example:
1447 /cdrom:/nfs/wuarchive:/afs
1450 Relative paths are supported also. The following example shows how to skip special
1451 directories of version control systems:
1453 /cdrom:/nfs/wuarchive:/afs:.svn:.git:CVS
1456 Attention: input field can contain a dot (.), this means the current absolute path.
1458 You may consider using the
1459 .\"LINK2"
1460 External panelize
1461 .\"External panelize"
1462 command for some operations. Find file command is for simple queries
1463 only, while using External panelize you can do as mysterious searches
1464 as you would like.
1465 .\"NODE "    External panelize"
1466 .SH "    External panelize"
1467 The External panelize allows you to execute an external program, and
1468 make the output of that program the contents of the current panel.
1470 For example, if you want to manipulate in one of the panels all the
1471 symbolic links in the current directory, you can use external
1472 panelization to run the following command:
1475 find . \-type l \-print
1478 Upon command completion, the directory contents of the panel will no
1479 longer be the directory listing of the current directory, but all the
1480 files that are symbolic links.
1482 If you want to panelize all of the files that have been downloaded
1483 from your FTP server, you can use this awk command to extract the file
1484 name from the transfer log files:
1487 awk '$9 ~! /incoming/ { print $9 }' < /var/log/xferlog
1490 You may want to save often used panelize commands under a descriptive name,
1491 so that you can recall them quickly. You do this by typing the command on
1492 the input line and pressing Add new button. Then you enter a name under
1493 which you want the command to be saved. Next time, you just choose that
1494 command from the list and do not have to type it again.
1495 .\"NODE "    Hotlist"
1496 .SH "    Hotlist"
1497 The Directory hotlist command shows the labels of the directories
1498 in the directory hotlist. Midnight Commander will change to the
1499 directory corresponding to the selected label.  From the hotlist dialog,
1500 you can remove already created label/directory pairs and add new ones.
1501 To add new directories quickly, you can use the Add to hotlist command
1502 (C\-x h), which adds the current directory into the directory hotlist,
1503 asking just for the label for the directory.
1505 This makes cd to often used directories faster. You may consider using the
1506 CDPATH variable as described in
1507 .\"LINK2"
1508 internal cd command
1509 .\"The cd internal command"
1510 description.
1511 .\"NODE "    Edit Extension File"
1512 .SH "    Edit Extension File"
1513 This will invoke your editor on the file
1514 .IR ~/.config/mc/mc.ext .
1515 The format of this file following:
1517 All lines starting with # or empty lines are thrown away.
1519 Lines starting in the first column should have following format:
1521 .IR keyword/expr ,
1522 i.e. everything after the slash until new line is
1523 .IR expr .
1525 .I keyword
1526 can be:
1528 .I shell
1530 .I expr
1531 is an extension (no wildcards).  File matches it its name ends
1532 with
1533 .IR expr .
1534 Example:
1535 .I shell/.tar
1536 matches
1537 .IR *.tar .
1539 .I regex
1541 .I expr
1542 is a regular expression.  File matches if its name matches the regular
1543 expression.
1545 .I directory
1547 .I expr
1548 is a regular expression.  File matches if it is a directory and its name
1549 matches the regular expression.
1551 .I type
1553 .I expr
1554 is a regular expression.  File matches if the output of
1555 .I file %f
1556 without the initial "filename:" part matches regular expression
1557 .IR expr .
1559 .I default
1560 \- matches any file.
1561 .I expr
1562 is ignored.
1564 .I include
1565 \- denotes a common section.
1566 .I expr
1567 is the name of the section.
1569 Other lines should start with a space or tab and should be of the format:
1570 .I keyword=command
1571 (with no spaces around =), where
1572 .I keyword
1573 should be:
1574 .I Open
1575 (invoked on Enter or double click),
1576 .I View
1577 (F3),
1578 .I Edit
1579 (F4) or
1580 .I Include
1581 (to add rules from the common section).
1582 .I command
1583 is any one\-line shell command, with the simple
1584 .\"LINK2"
1585 macro substitution\&.
1586 .\"Macro Substitution"
1588 Rules are matched from top to bottom, thus the order is important.  If
1589 the appropriate action is missing, search continues as if this rule
1590 didn't match (i.e. if a file matches the first and second entry and View
1591 action is missing in the first one, then on pressing F3 the View action
1592 from the second entry will be used).
1593 .I default
1594 should match all the actions.
1595 .\"NODE "    Background jobs"
1596 .SH "    Background Jobs"
1597 This lets you control the state of any background Midnight Commander
1598 process (only copy and move files operations can be done in the
1599 background).  You can stop, restart and kill a background job from
1600 here.
1601 .\"NODE "    Edit Menu File"
1602 .SH "    Edit Menu File"
1603 The user menu is a menu of useful actions that can be customized by
1604 the user. When you access the user menu, the
1605 file .mc.menu from the current directory is used if it exists,
1606 but only if it is owned by user or root and is not world\-writable.
1607 If no such file found, ~/.config/mc/menu is tried in the same way,
1608 and otherwise mc uses the default system\-wide menu
1609 %prefix%/share/mc/mc.menu.
1611 The format of the menu file is very simple. Lines that start with
1612 anything but space or tab are considered entries for the menu (in
1613 order to be able to use it like a hot key, the first character should
1614 be a letter). All the lines that start with a space or a tab are the
1615 commands that will be executed when the entry is selected.
1617 When an option is selected all the command lines of the option are
1618 copied to a temporary file in the temporary directory (usually
1619 /usr/tmp) and then that file is executed. This allows the user to put
1620 normal shell constructs in the menus. Also simple macro substitution
1621 takes place before executing the menu code. For more information, see
1622 .\"LINK2"
1623 macro substitution\&.
1624 .\"Macro Substitution"
1626 Here is a sample mc.menu file:
1629 A       Dump the currently selected file
1630         od \-c %f
1632 B       Edit a bug report and send it to root
1633         I=`mktemp ${MC_TMPDIR:\-/tmp}/mail.XXXXXX` || exit 1
1634         vi $I
1635         mail \-s "Midnight Commander bug" root < $I
1636         rm \-f $I
1638 M       Read mail
1639         emacs \-f rmail
1641 N       Read Usenet news
1642         emacs \-f gnus
1644 H       Call the info hypertext browser
1645         info
1647 J       Copy current directory to other panel recursively
1648         tar cf \- . | (cd %D && tar xvpf \-)
1650 K       Make a release of the current subdirectory
1651         echo \-n "Name of distribution file: "
1652         read tar
1653         ln \-s %d `dirname %d`/$tar
1654         cd ..
1655         tar cvhf ${tar}.tar $tar
1657 = f *.tar.gz | f *.tgz & t n
1658 X       Extract the contents of a compressed tar file
1659         tar xzvf %f
1662 .B Default Conditions
1664 Each menu entry may be preceded by a condition. The condition must
1665 start from the first column with a '=' character. If the condition is
1666 true, the menu entry will be the default entry.
1669 Condition syntax:       = <sub\-cond>
1670   or:                   = <sub\-cond> | <sub\-cond> ...
1671   or:                   = <sub\-cond> & <sub\-cond> ...
1673 Sub\-condition is one of following:
1675   y <pattern>           syntax of current file matching pattern?
1676                         (for edit menu only)
1677   f <pattern>           current file matching pattern?
1678   F <pattern>           other file matching pattern?
1679   d <pattern>           current directory matching pattern?
1680   D <pattern>           other directory matching pattern?
1681   t <type>              current file of type?
1682   T <type>              other file of type?
1683   x <filename>          is it executable filename?
1684   ! <sub\-cond>         negate the result of sub\-condition
1687 Pattern is a normal shell pattern or a regular expression, according
1688 to the shell patterns option. You can override the global value of
1689 the shell patterns option by writing "shell_patterns=x" on the first
1690 line of the menu file (where "x" is either 0 or 1).
1692 Type is one or more of the following characters:
1695   n     not a directory
1696   r     regular file
1697   d     directory
1698   l     link
1699   c     character device
1700   b     block device
1701   f     FIFO (pipe)
1702   s     socket
1703   x     executable file
1704   t     tagged
1707 For example 'rlf' means either regular file, link or fifo. The 't'
1708 type is a little special because it acts on the panel instead of the
1709 file. The condition '=t t' is true if there are tagged files in the
1710 current panel and false if not.
1712 If the condition starts with '=?' instead of '=' a debug trace will be
1713 shown whenever the value of the condition is calculated.
1715 The conditions are calculated from left to right. This means
1717         = f *.tar.gz | f *.tgz & t n
1719 is calculated as
1721         ( (f *.tar.gz) | (f *.tgz) ) & (t n)
1724 Here is a sample of the use of conditions:
1727 = f *.tar.gz | f *.tgz & t n
1728 L       List the contents of a compressed tar\-archive
1729         gzip \-cd %f | tar xvf \-
1732 .B Addition Conditions
1734 If the condition begins with '+' (or '+?') instead of '=' (or '=?') it
1735 is an addition condition. If the condition is true the menu entry will
1736 be included in the menu. If the condition is false the menu entry will
1737 not be included in the menu.
1739 You can combine default and addition conditions by starting condition
1740 with '+=' or '=+' (or '+=?' or '=+?' if you want debug trace). If you
1741 want to use two different conditions, one for adding and another for
1742 defaulting, you can precede a menu entry with two condition lines, one
1743 starting with '+' and another starting with '='.
1745 Comments are started with '#'. The additional comment lines must start
1746 with '#', space or tab.
1747 .\"NODE "  Options Menu"
1748 .SH "  Options Menu"
1749 Midnight Commander has some options that may be toggled on and
1750 off in several dialogs which are accessible from this menu. Options
1751 are enabled if they have an asterisk or "x" in front of them.
1754 .\"LINK2"
1755 Configuration
1756 .\"Configuration"
1757 command pops up a dialog from which you can change most of settings of
1758 Midnight Commander.
1761 .\"LINK2"
1762 Layout
1763 .\"Layout"
1764 command pops up a dialog from which you specify a bunch of options how mc
1765 looks like on the screen.
1768 .\"LINK2"
1769 Panel options
1770 .\"Panel options"
1771 command pops up a dialog from which you specify options of file manager panels.
1774 .\"LINK2"
1775 Confirmation
1776 .\"Confirmation"
1777 command pops up a dialog from which you specify which actions you want to
1778 confirm.
1781 .\"LINK2"
1782 Appearance
1783 .\"Appearance"
1784 command pops up a dialog from which you specify the skin.
1787 .\"LINK2"
1788 Display bits
1789 .\"Display bits"
1790 command pops up a dialog from which you may select which characters is your
1791 terminal able to display.
1794 .\"LINK2"
1795 Learn keys
1796 .\"Learn keys"
1797 command pops up a dialog from which you test some keys which are not working
1798 on some terminals and you may fix them.
1801 .\"LINK2"
1802 Virtual FS
1803 .\"Virtual FS"
1804 command pops up a dialog from which you specify some VFS related options.
1807 .\"LINK2"
1808 Save setup
1809 .\"Save Setup"
1810 command saves the current settings of the Left, Right and Options
1811 menus. A small number of other settings is saved, too.
1812 .\"NODE "    Configuration"
1813 .SH "    Configuration"
1814 The options in this dialog are divided into several groups: "File
1815 operation options", "Esc key mode", "Pause after run" and "Other options".
1817 .B File operation options
1819 .I Verbose operation.
1820 This toggles whether the file Copy, Rename and Delete operations are
1821 verbose (i.e., display a dialog box for each operation). If you have a
1822 slow terminal, you may wish to disable the verbose operation. It is
1823 automatically turned off if the speed of your terminal is less than
1824 9600 bps.
1826 .I Compute totals.
1827 If this option is enabled, Midnight Commander computes total byte
1828 sizes and total number of files prior to any Copy, Rename and Delete
1829 operations. This will provide you with a more accurate progress bar
1830 at the expense of some speed. This option has no effect, if
1831 .I Verbose  operation
1832 is disabled.
1834 .I Classic progressbar.
1835 If this option is enabled, the progressbar of Copy/Move/Delete operations
1836 is always grown form left to right. If disabled, the growing direction
1837 of progressbar follows to direction of Copy/Move/Delete operation:
1838 from left panel to right one and vice versa. Enabled by default.
1840 .I Mkdir autoname.
1841 When you press F7 to create a new directory, the input line in popup dialog
1842 will be filled by name of current file or directory in active panel.
1843 Disabled by default.
1845 .I Preallocate space.
1846 Preallocate space for whole target file, if possible, before copy operation.
1847 Disabled by default.
1849 .B Esc key mode.
1851 By default, Midnight Commander treats the ESC key as a key prefix.
1852 Therefore, you should press Esc code twice to exit a dialog. But there is
1853 a possibility to use a single press of ESC key for that action.
1855 .I Single press.
1856 By default this option is disabled. If you'll enable it, the ESC key
1857 will act as a prefix key for set up time interval (see
1858 .I Timeout
1859 option below), and if no extra keys have arrived, then the ESC key
1860 is interpreted as a cancel key (ESC ESC).
1862 .I Timeout.
1863 This options is used to setup the time interval (in microseconds)
1864 for single press of ESC key. By default, this interval is one second
1865 (1000000 microseconds). Also the timeout can be set via KEYBOARD_KEY_TIMEOUT_US
1866 environment variable (also in microseconds), which has higher priority
1867 than Timeout option value.
1869 .B Pause after run
1871 After executing your commands, Midnight Commander can pause, so
1872 that you can examine the output of the command.  There are three
1873 possible settings for this variable:
1875 .I Never.
1876 Means that you do not want to see the output of your command.  If you
1877 are using the Linux or FreeBSD console or an xterm, you will be able to
1878 see the output of the command by typing C\-o.
1880 .I On dumb terminals.
1881 You will get the pause message on terminals that are not capable of
1882 showing the output of the last command executed (any terminal that is
1883 not an xterm or the Linux console).
1885 .I Always.
1886 The program will pause after executing all of your commands.
1888 .B Other options
1890 .I Use internal editor.
1891 If this option is enabled, the built\-in file editor is used to edit
1892 files. If the option is disabled, the editor specified in the
1893 .B EDITOR
1894 environment variable is used.
1895 If no editor is specified,
1896 .B vi
1897 is used.  See the section on the
1898 .\"LINK2"
1899 internal file editor\&.
1900 .\"Internal File Editor"
1902 .I Use internal viewer.
1903 If this option is enabled, the built\-in file viewer is used to view
1904 files. If the option is disabled, the pager specified in the
1905 .B PAGER
1906 environment variable is used.
1907 If no pager is specified, the
1908 .B view
1909 command is used.  See the section on the
1910 .\"LINK2"
1911 internal file viewer\&.
1912 .\"Internal File Viewer"
1914 .I Ask new file name.
1915 If this option is enabled, file name is asked before open new file in editor.
1917 .I Auto menus.
1918 If this option is enabled, the user menu will be invoked at startup.
1919 Useful for building menus for non\-unixers.
1921 .I Drop down menus.
1922 When this option is enabled, the pull down menus will be activated as
1923 soon as you press the F9 key. Otherwise, you will only get the menu title,
1924 and you will have to activate the menu either with the arrow keys or with
1925 the hotkeys. It is recommended if you are using hotkeys.
1927 .I Shell Patterns.
1928 By default the Select, Unselect and Filter commands will use shell\-like
1929 regular expressions. The following conversions are performed to achieve
1930 this: the '*' is replaced by '.*' (zero or more characters); the '?'
1931 is replaced by '.' (exactly one character) and '.' by the literal
1932 dot. If the option is disabled, then the regular expressions are the
1933 ones described in ed(1).
1935 .I Complete: show all.
1936 By default, Midnight Commander pops up all possible
1937 .\"LINK2"
1938 completions
1939 .\"Completion"
1940 if the completion is ambiguous only when you press
1941 .B Alt\-Tab
1942 for the second time.  For the first time, it just completes as much as
1943 possible and beeps in the case of ambiguity.  Enable this option if you
1944 want to see all possible completions even after pressing
1945 .B Alt\-Tab
1946 the first time.
1948 .I Rotating dash.
1949 If this option is enabled, the
1950 Midnight Commander shows a rotating dash in the upper right corner
1951 as a work in progress indicator.
1953 .I Cd follows links.
1954 This option, if set, causes Midnight Commander to follow the
1955 logical chain of directories when changing current directory
1956 either in the panels, or using the cd command. This is the default
1957 behavior of bash. When unset, Midnight Commander follows the
1958 real directory structure, so cd .. if you've entered that directory
1959 through a link will move you to the current directory's real parent
1960 and not to the directory where the link was present.
1962 .I Safe delete.
1963 If this option is enabled, deleting files and directory hotlist entries
1964 unintentionally becomes more difficult.  The default selection in the
1965 confirmation dialogs for deletion changes from
1966 .B Yes
1968 .BR No .
1969 This option is disabled by default.
1971 .I Safe overwrite.
1972 If this option is enabled, overwriting files unintentionally becomes
1973 more difficult.  The default selection in the overwrite confirmation dialog
1974 changes from
1975 .B Yes
1977 .BR No .
1978 This option is disabled by default.
1980 .I Auto save setup.
1981 If this option is enabled, when you exit Midnight Commander, the
1982 configurable options of Midnight Commander are saved in the
1983 ~/.config/mc/ini file.
1984 .\"NODE "    Layout"
1985 .SH "    Layout"
1986 The layout dialog gives you a possibility to change the general layout
1987 of screen. The options in this dialog are divided into several groups:
1988 "Panel split", "Console output" and "Other options".
1990 .B Panel split
1992 The rest of the screen area is used for the two directory panels. You
1993 can specify whether the area is split to the panels in
1994 .I Vertical
1996 .I Horizontal
1997 direction. Panel layout can be changed using Alt\-, (Alt\-comma) shortcut.
1999 .I Equal split.
2000 By default, panels have equal sizes. Using this option you can specify
2001 an unequal split.
2003 .B Console output
2005 On the Linux or FreeBSD console you can specify how many lines are shown
2006 in the output window. This option is available if Midnight Commander runs
2007 on native console only.
2009 .B Other options
2011 .I Menu bar visible.
2012 If enabled, main menu of Midnight Commander is always visible on the top row
2013 of screen above panels. Enabled by default.
2015 .I Command prompt.
2016 If enabled, command line is available. Enabled by default.
2018 .I Keybar visible.
2019 If enabled, 10 labels associated with F1\-F10 keys are located at the bottom
2020 row of screen. Enabled by default.
2022 .I Hintbar visible.
2023 If enabled, the one\-line hints are visible below panels. Enabled by default.
2025 .I XTerm window title.
2026 When run in a terminal emulator for X11, Midnight Commander sets the
2027 terminal window title to the current working directory and updates it
2028 when necessary.  If your terminal emulator is broken and you see some
2029 incorrect output on startup and directory change, turn off this option.
2030 Enabled by default.
2032 .I Show free space.
2033 If enabled, free space and total space of current file system is shown
2034 at the bottom frame of panel. Enabled by default.
2035 .\"NODE "    Panel options"
2036 .SH "    Panel options"
2037 .B Main panel options
2039 .I Show mini\-status.
2040 If enabled, one line of status information about the currently selected item
2041 is shown at the bottom of the panels. Enabled by default.
2043 .I Use SI size units.
2044 If this option is enabled, Midnight Commander will use SI prefixes (base 10)
2045 when displaying any byte sizes. If disabled (default), Midnight Commander will
2046 use IEC prefixes (base 2).
2048 .I Mix all files.
2049 If this option is enabled, all files and directories are shown mixed
2050 together.  If the option is disabled (default), directories (and links to
2051 directories) are shown at the beginning of the listing, and other files below.
2053 .I Show backup files.
2054 If enabled, Midnight Commander will show files ending with a tilde.
2055 Otherwise, they won't be shown (like GNU's ls option \-B). Enabled by default.
2057 .I Show hidden files.
2058 If enabled, Midnight Commander will show all files that start with
2059 a dot (like ls \-a). Disabled by default.
2061 .I Fast directory reload.
2062 If this option is enabled, Midnight Commander will use a trick to
2063 determine if the directory contents have changed.  The trick is to reload
2064 the directory only if the i\-node of the directory has changed; this means
2065 that reloads only happen when files are created or deleted.  If what
2066 changes is the i\-node for a file in the directory (file size changes,
2067 mode or owner changes, etc) the display is not updated.  In these cases,
2068 if you have the option on, you have to rescan the directory manually
2069 (with C\-r). Disabled by default.
2071 .I Mark moves down.
2072 If enabled, the selection bar will move down when you mark a file (with
2073 Insert key). Enabled by default.
2075 .I Reverse files only.
2076 Allow revert selection of files only. Enabled by default.
2077 If enabled, the reverse selection is applied to files only, not to directories.
2078 The selection of directories is untouched. If off, the reverse selection
2079 is applied to files as well to directories: all unselected items become
2080 selected, and vice versa.
2082 .I Simple swap.
2083 If both panels contain file listing, simple swap means that panels exchange
2084 its screen positions: left panel become right one, and vice versa. If this
2085 option is unchecked, file listing panels exchange its content keeping listing
2086 format and sort options. Unchecked by default.
2088 .I Auto save panels setup.
2089 If this option is enabled, when you exit Midnight Commander, the
2090 current settings of panels are saved in the ~/.config/mc/panels.ini file.
2091 Disabled by default.
2093 .B Navigation
2095 .I Lynx\-like motion.
2096 If this option is enabled, you may use the arrows keys to automatically
2097 chdir if the current selection is a subdirectory and the shell command
2098 line is empty. By default, this setting is off.
2100 .I Page scrolling.
2101 If set (the default), panel will scroll by half the display when the
2102 cursor reaches the end or the beginning of the panel, otherwise it
2103 will just scroll a file at a time.
2105 .I Center scrolling.
2106 If set, panel will scroll when the cursor reaches the middle of the
2107 panel column, only hitting the top or bottom of the panel when actually on
2108 the first or last file. This behavior applies when scrolling one file
2109 at a time, and does not apply to the page up/down keys.
2111 .I Mouse page scrolling.
2112 Controls whenever scrolling with the mouse wheel is done by pages or
2113 line by line on the panels.
2115 .B File highlight
2117 You can specify whether
2118 .I permissions
2120 .I file types
2121 should be highlighted with distinctive
2122 .\"LINK2"
2123 Colors\&.
2124 .\"Colors"
2125 If the permission highlighting is enabled, the parts of the
2126 .I perm
2128 .I mode
2129 .\"LINK2"
2130 display fields
2131 .\"Listing Format..."
2132 which apply to the user running Midnight Commander are highlighted with
2133 the color defined by the
2134 .I selected
2135 keyword.  If the file type highlighting is enabled, file names are colored
2136 according to rules described in
2137 %sysconfdir%/mc/filehighlight.ini
2138 file. See
2139 .\"LINK2"
2140 Filenames Highlight
2141 .\"Filenames Highlight"
2142 for more info.
2144 .B Quick search
2146 You can specify how the
2147 .\"LINK2"
2148 Quick search
2149 .\"Quick search"
2150 mode should work: case insensitively, case sensitively or be matched
2151 to the panel sort order: case sensitive or not.
2152 .\"NODE "    Confirmation"
2153 .SH "    Confirmation"
2154 In this dialog you configure the confirmation options for file deletion,
2155 overwriting files, execution by pressing enter, quitting the program,
2156 directory hotlist entries deletion and history cleanup.
2157 .\"NODE "    Appearance"
2158 .SH "    Appearance"
2159 In this dialog you can select the skin to be used.
2161 See the
2162 .\"LINK2"
2163 Skins
2164 .\"Skins"
2165 section for technical details about the skin definition files.
2166 .\"NODE "    Display bits"
2167 .SH "    Display bits"
2168 This is used to configure the range of visible characters on the
2169 screen.  This setting may be 7\-bits if your terminal/curses supports
2170 only seven output bits, ISO\-8859\-1 displays all the characters in the
2171 ISO\-8859\-1 map and full 8 bits is for those terminals that can display
2172 full 8 bit characters.
2173 .\"NODE "    Learn keys"
2174 .SH "    Learn keys"
2175 This dialog allows you to test and redefine functional keys, cursor
2176 arrows and some other keys to make them work properly on your terminal.
2177 They often don't, since many terminal databases are incomplete or broken.
2179 You can move around with the Tab key and with the vi moving keys ('h'
2180 left, 'j' down, 'k' up and 'l' right).  Once you press any cursor movement
2181 key and it is recognized, you can use that key as well.
2183 You can test keys just by pressing each of them.  When you press a
2184 key and it is recognized properly, OK should appear next to the name
2185 of that key.  Once a key is marked OK it starts working as usually,
2186 e.g. F1 pressed the first time will just check that the F1 key works,
2187 but after that it will show help.  The same applies to the arrow keys.
2188 The Tab key should be working always.
2190 If some keys do not work properly then you won't see OK appear after
2191 pressing one of these.  Then you may want to redefine it.  Do it by pressing
2192 the button with the name of that key (either by the mouse or by Enter
2193 or Space after selecting the button with Tab or arrows).  Then a message
2194 box will appear asking you to press that key.  Do it and wait until the
2195 message box disappears.  If you want to abort, just press Escape once
2196 and wait.
2198 When you finish with all the keys, you can Save them.  The definitions
2199 for the keys you have redefined will be written into the [terminal:TERM]
2200 section of your ~/.config/mc/ini file (where TERM is the name of your current
2201 terminal).  The definitions of the keys that were already working properly
2202 are not saved.
2203 .\"NODE "    Virtual FS"
2204 .SH "    Virtual FS"
2205 This option gives you control over the settings of the
2206 .\"LINK2"
2207 Virtual File System\&.
2208 .\"Virtual File System"
2210 Midnight Commander keeps in memory the information related to some
2211 of the virtual file systems to speed up the access to the files in the
2212 file system (for example, directory listings fetched from FTP servers).
2214 Also, in order to access the contents of compressed files (for example,
2215 compressed tar files), Midnight Commander needs to create temporary
2216 uncompressed files on your disk.
2218 Since both the information in memory and the temporary files on disk
2219 take up resources, you may want to tune the parameters of the cached
2220 information to decrease your resource usage or to maximize the speed of
2221 access to frequently used file systems.
2223 Because of the format of the tar archives, the
2224 .I Tar filesystem
2225 needs to read the whole file just to load the file entries.  Since most
2226 tar files are usually kept compressed (plain tar files are species in
2227 extinction), the tar file system has to uncompress the file on the disk
2228 in a temporary location and then access the uncompressed file as a
2229 regular tar file.
2231 Now, since we all love to browse files and tar files all over the disk,
2232 it's common that you will leave a tar file and then re\-enter it later.
2233 Since decompression is slow, Midnight Commander will cache the
2234 information in memory for a limited time.  When the timeout expires, all
2235 the resources associated with the file system are released.  The default
2236 timeout is set to one minute.
2239 .\"LINK2"
2240 FTP File System
2241 .\"FTP File System"
2242 (ftpfs) allows you to browse directories on remote FTP servers.  It has
2243 several options.
2245 .I ftp anonymous password
2246 is the password used when you login as "anonymous".  Some sites require
2247 a valid e\-mail address.  On the other hand, you probably don't want to
2248 give your real e\-mail address to untrusted sites, especially if you are
2249 not using spam filtering.
2251 ftpfs keeps the directory listing it fetches from a FTP server in a cache.
2252 The cache expire time is configurable with the
2253 .I ftpfs directory cache timeout
2254 option.  A low value for this option may slow down every operation on
2255 the ftpfs because every operation would require sending a request to the
2256 FTP server.
2258 You can define an FTP proxy host for doing FTP.  Note that most modern
2259 firewalls are fully transparent at least for passive FTP (see below), so
2260 FTP proxies are considered obsolete.
2263 .I Always use ftp proxy
2264 is not set, you can use the exclamation sign to enable proxy for certain
2265 hosts.  See
2266 .\"LINK2"
2267 FTP File System
2268 .\"FTP File System"
2269 for examples.
2271 If this option is set, the program will do two things: consult the
2272 %prefix%/lib/mc/mc.no_proxy file for lines containing host names that
2273 are local (if the host name starts with a dot, it is assumed to be a
2274 domain) and to assume that any hostnames without dots in their names are
2275 directly accessible.  All other hosts will be accessed through the
2276 specified FTP proxy.
2278 You can enable using
2279 .I ~/.netrc
2280 file, which keeps login names and passwords for ftp servers.  See netrc
2281 (5) for the description of the .netrc format.
2283 .I Use passive mode
2284 enables using FTP passive mode, when the connection for data transfer is
2285 initiated by the client, not by the server.  This option is recommended
2286 and enabled by default.  If this option is turned off, the data
2287 connection is initiated by the server.  This may not work with some
2288 firewalls.
2289 .\"NODE "    Save Setup"
2290 .SH "    Save Setup"
2291 At startup, Midnight Commander will try to load initialization
2292 information from the ~/.config/mc/ini file. If this file
2293 doesn't exist, it will load the information from the system\-wide
2294 configuration file, located in %prefix%/share/mc/mc.ini. If the 
2295 system\-wide configuration file doesn't exist, MC uses the default settings.
2298 .I Save Setup
2299 command creates the ~/.config/mc/ini file by saving the
2300 current settings of the
2301 .\"LINK2"
2302 Left, Right
2303 .\"Left and Right Menus"
2305 .\"LINK2"
2306 Options
2307 .\"Options Menu"
2308 menus.
2310 If you activate the
2311 .I auto save setup
2312 option, MC will always save the current settings when exiting.
2314 There also exist settings which can't be changed from the menus. To
2315 change these settings you have to edit the setup file with your
2316 favorite editor. See the section on
2317 .\"LINK2"
2318 Special Settings
2319 .\"Special Settings"
2320 for more information.
2321 .SH ""
2322 .\"NODE "Executing operating system commands"
2323 .SH "Executing operating system commands"
2324 You may execute commands by typing them directly in Midnight
2325 Commander's input line, or by selecting the program you want to
2326 execute with the selection bar in one of the panels and hitting Enter.
2328 If you press Enter over a file that is not executable, Midnight
2329 Commander checks the extension of the selected file against the
2330 extensions in the
2331 .\"LINK2"
2332 Extensions File\&.
2333 .\"Edit Extension File"
2334 If a match is found then the code associated with that extension is
2335 executed. A very simple
2336 .\"LINK2"
2337 macro expansion
2338 .\"Macro Substitution"
2339 takes place before executing the command.
2340 .\"NODE "  The cd internal command"
2341 .SH "  The cd internal command"
2343 .I cd
2344 command is interpreted by Midnight Commander, it is not passed to
2345 the command shell for execution.  Thus it may not handle all of the
2346 nice macro expansion and substitution that your shell does, although it
2347 does some of them:
2349 .I Tilde substitution.
2350 The (~) will be substituted with your home directory, if you append a
2351 username after the tilde, then it will be substituted with the login
2352 directory of the specified user.
2354 For example, ~guest is the home directory for the user guest, while
2355 ~/guest is the directory guest in your home directory.
2357 .I Previous directory.
2358 You can jump to the directory you were previously by using the special
2359 directory name '\-' like this:
2360 .B cd \-
2362 .I CDPATH directories.
2363 If the directory specified to the
2364 .B cd
2365 command is not in the current directory, then Midnight Commander
2366 uses the value in the environment variable
2367 .B CDPATH
2368 to search for the directory in any of the named directories.
2370 For example you could set your
2371 .B CDPATH
2372 variable to ~/src:/usr/src, allowing you to change your directory to
2373 any of the directories inside the ~/src and /usr/src directories, from
2374 any place in the file system by using its relative name (for example
2375 cd linux could take you to /usr/src/linux).
2376 .\"NODE "  Macro Substitution"
2377 .SH "  Macro Substitution"
2378 When accessing a
2379 .\"LINK2"
2380 user menu\&,
2381 .\"Edit Menu File"
2382 or executing an
2383 .\"LINK2"
2384 extension dependent command\&,
2385 .\"Edit Extension File"
2386 or running a command from the command line input, a simple macro
2387 substitution takes place.
2389 The macros are:
2391 .I %i
2392 The indent of blank space, equal the cursor column position.  For edit
2393 menu only.
2395 .I %y
2396 The syntax type of current file. For edit menu only.
2398 .I %k
2399 The block file name.
2401 .I %e
2402 The error file name.
2404 .I %m
2405 The current menu name.
2407 .IR %f " and " %p
2408 In file manager user menu: the current file name in selected panel.
2409 In mcedit user menu: the name of opened file.
2411 .I %x
2412 The extension of current file name.
2414 .I %b
2415 The current file name without extension.
2417 .I %d
2418 The current directory name.
2420 .I %F
2421 The current file in the unselected panel.
2423 .I %D
2424 The directory name of the unselected panel.
2426 .I %t
2427 The currently tagged files.
2429 .I %T
2430 The tagged files in the unselected panel.
2432 .IR %u " and " %U
2433 Similar to the %t and %T macros, but in addition the files are untagged.
2434 You can use this macro only once per menu file entry or extension file
2435 entry, because next time there will be no tagged files.
2437 .IR %s " and " %S
2438 The selected files: The tagged files if there are any. Otherwise the
2439 current file.
2441 .I %cd
2442 This is a special macro that is used to change the current directory
2443 to the directory specified in front of it.  This is used primarily as
2444 an interface to the
2445 .\"LINK2"
2446 Virtual File System\&.
2447 .\"Virtual File System"
2449 .I %view
2450 This macro is used to invoke the internal viewer.  This macro can be
2451 used alone, or with arguments.  If you pass any arguments to this
2452 macro, they should be enclosed in brackets.
2454 The arguments are:
2455 .I ascii
2456 to force the viewer into ascii mode;
2457 .I hex
2458 to force the viewer into hex mode;
2459 .I nroff
2460 to tell the viewer that it should interpret the bold and underline
2461 sequences of nroff;
2462 .I unformatted
2463 to tell the viewer to not interpret nroff commands for making the text
2464 bold or underlined.
2466 .I %%
2467 The % character
2469 .I %{some text}
2470 Prompt for the substitution. An input box is shown and the text inside
2471 the braces is used as a prompt. The macro is substituted by the text
2472 typed by the user. The user can press ESC or F10 to cancel. This macro
2473 doesn't work on the command line yet.
2475 .I %var{ENV:default}
2476 If environment variable
2477 .I ENV
2478 is unset, the
2479 .I default
2480 is substituted.  Otherwise, the value of
2481 .I ENV
2482 is substituted.
2483 .\"NODE "  The subshell support"
2484 .SH "  The subshell support"
2485 The subshell support is a compile time option, that works with the
2486 shells: bash, ash (BusyBox and Debian), tcsh, zsh and fish.
2488 When the subshell support is active, Midnight Commander will
2489 spawn a concurrent copy of your shell (the one defined in the
2490 .B SHELL
2491 variable and if it is not defined, then the one in the /etc/passwd
2492 file) and run it in a pseudo terminal, instead of invoking a new shell
2493 each time you execute a command, the command will be passed to the
2494 subshell as if you had typed it.  This also allows you to change the
2495 environment variables, use shell functions and define aliases that are
2496 valid until you quit Midnight Commander.
2498 .B bash
2499 users may specify startup commands in ~/.local/share/mc/bashrc (fallback ~/.bashrc)
2500 and special keyboard maps in ~/.local/share/mc/inputrc (fallback ~/.inputrc).
2502 .B ash/dash
2503 users (BusyBox or Debian) may specify startup commands in ~/.local/share/mc/ashrc (fallback ~/.profile).
2505 .B tcsh, zsh, fish
2506 users cannot specify mc-specific startup commands at present. They have to rely on
2507 shell-specific startup files.
2509 The following paragraphs are relevant only when the subshell support is
2510 active:
2512 You can suspend applications at any
2513 time with the sequence C\-o and jump back to Midnight Commander, if
2514 you interrupt an application, you will not be able to run other
2515 external commands until you quit the application you interrupted.
2517 The basic prompt displayed by Midnight Commander is of the form
2518 "user@host:current_path$ ". When using a capable shell, like Bash, the
2519 prompt displayed by Midnight Commander will be the same prompt that you
2520 are currently using in your shell.
2522 (There's a known problem when using fish: the prompt is displayed only in
2523 full screen mode (Ctrl-o), not when the panels are visible.)
2526 .\"LINK2"
2527 OPTIONS
2528 .\"OPTIONS"
2529 section has more information on how you can control subshell usage (-U/-u).
2530 Furthermore, to set a specific subshell different from your current SHELL variable or
2531 login shell defined in /etc/passwd, you may call MC like this:
2532 .B SHELL=/bin/myshell mc
2533 .\"NODE "Chmod"
2534 .SH "Chmod"
2535 The Chmod window is used to change the attribute bits in a group of
2536 files and directories.  It can be invoked with the C\-x c key combination.
2538 The Chmod window has two parts \-
2539 .I Permissions
2541 .IR File .
2543 In the File section are displayed the name of the file or directory
2544 and its permissions in octal form, as well as its owner and group.
2546 In the Permissions section there is a set of check buttons which
2547 correspond to the file attribute bits.  As you change the attribute
2548 bits, you can see the octal value change in the File section.
2550 To move between the widgets (buttons and check buttons) use the
2551 .I arrow keys
2552 or the
2553 .I Tab
2554 key.  To change the state of the check buttons or to select a button
2556 .I Space.
2557 You can also use the hotkeys on the buttons to quickly activate them.
2558 Hotkeys are shown as highlighted letters on the buttons.
2560 To set the attribute bits, use the Enter key.
2562 When working with a group of files or directories, you just click on
2563 the bits you want to set or clear.  Once you have selected the bits
2564 you want to change, you select one of the action buttons (Set marked
2565 or Clear marked).
2567 Finally, to set the attributes exactly to those specified, you can use
2569 .B [Set all]
2570 button, which will act on all the tagged files.
2572 .B [Marked all]
2573 set only marked attributes to all selected files
2575 .B [Set marked]
2576 set marked bits in attributes of all selected files
2578 .B [Clean marked]
2579 clear marked bits in attributes of all selected files
2581 .B [Set]
2582 set the attributes of one file
2584 .B [Cancel]
2585 cancel the Chmod command
2586 .\"NODE "Chown"
2587 .SH "Chown"
2588 The Chown command is used to change the owner/group of a file. The hot
2589 key for this command is C\-x o.
2590 .\"NODE "Advanced Chown"
2591 .SH "Advanced Chown"
2592 The Advanced Chown command is the
2593 .\"LINK2"
2594 Chmod
2595 .\"Chmod"
2597 .\"LINK2"
2598 Chown
2599 .\"Chown"
2600 command combined into one window. You can change the permissions and
2601 owner/group of files at once.
2602 .\"NODE "File Operations"
2603 .SH "File Operations"
2604 When you copy, move or delete files, Midnight Commander shows the
2605 file operations dialog.  It shows the files currently being processed
2606 and uses up to three progress bars.  The file bar indicates the
2607 percentage of the current file that has been processed so far.  The
2608 count bar shows how many of the tagged files have been handled.  The
2609 bytes bar indicates the percentage of the total size of the tagged files
2610 that has been handled.  If the verbose option is off, the file and bytes
2611 bars are not shown.
2613 There are two buttons at the bottom of the dialog. Pressing the Skip
2614 button will skip the rest of the current file. Pressing the Abort
2615 button will abort the whole operation, the rest of the files are
2616 skipped.
2618 There are three other dialogs which you can run into during the file
2619 operations.
2621 The error dialog informs about error conditions and has three choices.
2622 Normally you select either the Skip button to skip the file or the Abort
2623 button to abort the operation altogether.  You can also select the Retry
2624 button if you fixed the problem from another terminal.
2626 The replace dialog is shown when you attempt to copy or move a file on
2627 the top of an existing file.  The dialog shows the dates and sizes of
2628 the both files.  Press the Yes button to overwrite the file, the No
2629 button to skip the file, the All button to overwrite all the files, the
2630 None button to never overwrite and the Update button to overwrite if the
2631 source file is newer than the target file.  You can abort the whole
2632 operation by pressing the Abort button.
2634 The recursive delete dialog is shown when you try to delete a directory
2635 which is not empty.  Press the Yes button to delete the directory
2636 recursively, the No button to skip the directory, the All button to
2637 delete all the directories and the None button to skip all the non\-empty
2638 directories.  You can abort the whole operation by pressing the Abort
2639 button.  If you selected the Yes or All button you will be asked for a
2640 confirmation.  Type "yes" only if you are really sure you want to do the
2641 recursive delete.
2643 If you have tagged files and perform an operation on them only the files
2644 on which the operation succeeded are untagged. Failed and skipped files
2645 are left tagged.
2646 .\"NODE "Mask Copy/Rename"
2647 .SH "Mask Copy/Rename"
2648 The copy/move operations let you translate the names of files in an
2649 easy way.  To do it, you have to specify the correct source mask and
2650 usually in the trailing part of the destination specify some wildcards.
2651 All the files matching the source mask are copied/renamed according to
2652 the target mask.  If there are tagged files, only the tagged files
2653 matching the source mask are renamed.
2655 There are other options which you can set:
2657 .B Follow links
2659 determines whether make the symlinks and hardlinks in the source
2660 directory (recursively in subdirectories) new links in the target
2661 directory or whether would you like to copy their content.
2663 .B Dive into subdirs
2665 determines the behavior when the source directory is about to be copied,
2666 but the target directory already exists.  The default action is to copy
2667 the contents of the source directory into the target directory.
2668 Enabling this option causes copying the source directory itself into the
2669 target directory.
2671 For example, you want to copy directory
2672 .I /foo
2673 containing file
2674 .I bar
2676 .IR /bla/foo ,
2677 which is an already existing directory.  Normally (when
2678 .B Dive into subdirs
2679 is not set), mc would copy file
2680 .I /foo/bar
2681 into the file
2682 .IR /bla/foo/bar .
2683 By enabling this option the
2684 .I /bla/foo/foo
2685 directory will be created, and
2686 .I /foo/bar
2687 will be copied into
2688 .IR /bla/foo/foo/bar .
2690 .B Preserve attributes
2692 determines whether to preserve the permissions, timestamps and (if you
2693 are root) the ownership of the original files.  If this option is not
2694 set, the current value of the umask will be respected.
2696 .B Use shell patterns
2698 When this option is on you can use the '*' and '?' wildcards in the source
2699 mask. They work like they do in the shell. In the target mask only the '*'
2700 and '\\<digit>' wildcards are allowed. The first '*' wildcard in the target
2701 mask corresponds to the first wildcard group in the source mask,
2702 the second '*' corresponds to the second group and so on.  The '\\1' wildcard
2703 corresponds to the first wildcard group in the source mask, the '\\2' wildcard
2704 corresponds to the second group and so on all the way up to '\\9'.
2705 The '\\0' wildcard is the whole filename of the source file.
2707 Two examples:
2709 If the source mask is "*.tar.gz", the destination is "/bla/*.tgz" and the
2710 file to be copied is "foo.tar.gz", the copy will be "foo.tgz" in "/bla".
2712 Suppose you want to swap basename and extension so that "file.c" would
2713 become "c.file" and so on.  The source mask for this is "*.*" and the
2714 destination is "\\2.\\1".
2716 .B Use shell patterns off
2718 When the shell patterns option is off the MC doesn't do automatic
2719 grouping anymore. You must use '\\(...\\)' expressions in the source
2720 mask to specify meaning for the wildcards in the target mask. This is
2721 more flexible but also requires more typing. Otherwise target masks
2722 are similar to the situation when the shell patterns option is on.
2724 Two examples:
2726 If the source mask is "^\\(.*\\)\\.tar\\.gz$", the destination is
2727 "/bla/*.tgz" and the file to be copied is "foo.tar.gz", the copy
2728 will be "/bla/foo.tgz".
2730 Let's suppose you want to swap basename and extension so that "file.c"
2731 will become "c.file" and so on. The source mask for this is
2732 "^\\(.*\\)\\.\\(.*\\)$" and the destination is "\\2.\\1".
2734 .B Case Conversions
2736 You can also change the case of the filenames.  If you use '\\u'
2737 or '\\l' in the target mask, the next character will be converted to
2738 uppercase or lowercase correspondingly.
2740 If you use '\\U' or '\\L' in the target mask, the next characters will
2741 be converted to uppercase or lowercase correspondingly up to the
2742 next '\\E' or next '\\U', '\\L' or the end of the file name.
2744 The '\\u' and '\\l' are stronger than '\\U' and '\\L'.
2746 For example, if the source mask is '*' (
2747 .I Use shell patterns
2748 on) or '^\\(.*\\)$' (
2749 .I Use shell patterns
2750 off) and the target mask is '\\L\\u*' the file names will be converted
2751 to have initial upper case and otherwise lower case.
2753 You can also use '\\' as a quote character. For example, '\\\\' is
2754 a backslash and '\\*' is an asterisk.
2756 .B Stable symlinks
2758 commands Midnight Commander, that it should change symlinks in the target,
2759 so that they'll point to the same location as it did before. With absolute
2760 symbolic links this does nothing, but if you have a relative one, it will
2761 recompute its value, adding necessary ../ and other directory parts and making
2762 the value as short as possible (most modern filesystems keep short symlinks
2763 inside inodes and thus don't waste much disk space).
2765 .\"NODE "Select/Unselect Files"
2766 .SH "Select/Unselect Files"
2767 The dialog of group of files and directories selection or uselection.
2769 .\"LINK2"
2770 input line
2771 .\"Input Line Keys"
2772 allow enter the regular expression of filenames that will be
2773 selected/unselected.
2775 When
2776 .I Files only
2777 checkbox is on, only files will be selected.  If
2778 .I Files only
2779 is off, as files as directories will be selected.
2780 When
2781 .I Shell Patterns
2782 checkbox is on, the regular expression is much like the filename globbing
2783 in the shell (* standing for zero or more characters and ?  standing
2784 for one character). If
2785 .I Shell Patterns
2786 is off, then the tagging of files is done with normal regular
2787 expressions (see ed (1)). When
2788 .I Case sensitive
2789 checkbox is on, the selection will be case sensitive characters.
2791 .I Case sensitive
2792 is off, the case will be ignored.
2793 .\"NODE "Diff Viewer"
2794 .SH "Internal Diff Viewer"
2795 The mcdiff is a visual diff tool. You can compare two files and edit them
2796 in\-place (diffs are updated dynamically). You can browse and view a working
2797 copy from popular version control systems (GIT, Subversion, etc).
2799 Following shortcuts are available in internal diff viewer of Midnight
2800 Commander.
2802 .B F1
2803 Invoke the built\-in hypertext help viewer.
2805 .B F2
2806 Save modified files.
2808 .B F4
2809 Edit file of the left panel in the internal editor.
2811 .B F14
2812 Edit file of the right panel in the internal editor.
2814 .B F5
2815 Merge the current hunk. Only the current hunk will be merged.
2817 .B F7
2818 Start search.
2820 .B F17
2821 Continue search.
2823 .B F10, Esc, q
2824 Exit from diff viewer.
2826 .B Alt\-s, s
2827 Toggle show of hunk status.
2829 .B Alt\-n, l
2830 Toggle show of line numbers.
2832 .B f
2833 Maximize left panel.
2835 .B =
2836 Make panels equal in width.
2838 .B >
2839 Reduce the size of the right panel.
2841 .B <
2842 Reduce the size of the left panel.
2844 .B c
2845 Toggle show of trailing carriage return (CR) symbol as ^M.
2847 .B 2, 3, 4, 8
2848 Set tabulation size
2850 .B C\-u
2851 Swap contents of diff panels.
2853 .B C\-r
2854 Refresh the screen.
2856 .B C\-o
2857 Switch to the subshell and show the command screen.
2859 .B Enter, Space, n
2860 Find next diff hunk.
2862 .B Backspace, p
2863 Find previous diff hunk.
2865 .B g
2866 Go to line.
2868 .B Down
2869 Scroll one line forward.
2871 .B Up
2872 Scroll one line backward.
2874 .B PageUp
2875 Move one page up.
2877 .B PageDown
2878 Mves one page down.
2880 .B Home, A1
2881 Moves to the line beginning.
2883 .B End
2884 Moves to the line end.
2886 .B C\-Home
2887 Move to the file beginning.
2889 .B C\-End, C1
2890 Move to the file end.
2891 .\"NODE "Internal File Viewer"
2892 .SH "Internal File Viewer"
2893 The internal file viewer provides two display modes: ASCII and hex.
2894 To toggle between modes, use the F4 key.
2896 The viewer will try to use the best method provided by your system or
2897 the file type to display the information.
2898 Some character sequences, which appear most often in preformatted manual
2899 pages, are displayed bold and underlined, thus making a pretty display
2900 of your files.
2902 When in hex mode, the search function accepts text in quotes and
2903 constant numbers.  Text in quotes is matched exactly after removing
2904 the quotes.  Each number matches one byte.  You can mix quoted text
2905 with constants like this:
2908 "String" 34 0xBB 012 "more text"
2911 Numbers are always interpreted in hex. In the example above, "34" is
2912 interpreted as 0x34. The prefix "0x" isn't really needed: we could type
2913 "BB" instead of "0xBB". And "012" is interpreted as 0x12, not as an octal
2914 number.
2916 Here is a listing of the actions associated with each key that the
2917 Midnight Commander handles in the internal file viewer.
2919 .B F1
2920 Invoke the built\-in hypertext help viewer.
2922 .B F2
2923 Toggle the wrap mode.
2925 .B F4
2926 Toggle the hex mode.
2928 .B F5
2929 Goto line.  This will prompt you for a line number and will display
2930 that line.
2932 .B F6, /.
2933 Regular expression search.
2935 .B ?,
2936 Reverse regular expression search.
2938 .B F7
2939 Normal search / hex mode search.
2941 .B C\-s, F17, n.
2942 Start normal search if there was no previous search expression else
2943 find next match.
2945 .B C\-r.
2946 Start reverse search if there was no previous search expression else
2947 find next match.
2949 .B F8
2950 Toggle Raw/Parsed mode: This will show the file as found on disk or if
2951 a processing filter has been specified in the mc.ext file, then the
2952 output from the filter. Current mode is always the other than written
2953 on the button label, since on the button is the mode which you enter
2954 by that key.
2956 .B F9
2957 Toggle the format/unformat mode: when format mode is on the viewer
2958 will interpret some string sequences to show bold and underline with
2959 different colors. Also, on button label is the other mode than current.
2961 .B F10, Esc.
2962 Exit the internal file viewer.
2964 .B next\-page, space, C\-v.
2965 Scroll one page forward.
2967 .B prev\-page, Alt\-v, C\-b, Backspace.
2968 Scroll one page backward.
2970 .B down\-key
2971 Scroll one line forward.
2973 .B up\-key
2974 Scroll one line backward.
2976 .B C\-l
2977 Refresh the screen.
2979 .B C\-o
2980 Switch to the subshell and show the command screen.
2982 .B "[n] m"
2983 Set the mark n.
2985 .B "[n] r"
2986 Jump to the mark n.
2988 .B C\-f
2989 Jump to the next file.
2991 .B C\-b
2992 Jump to the previous file.
2994 .B Alt\-r
2995 Toggle the ruler.
2997 .B Alt\-e
2998 to change charset of displayed text may use M\-e (Alt\-e).
2999 Recoding is made from selected codepage into system codepage. To
3000 cancel the recoding you may select "<No translation>" in charset
3001 selection dialog.
3003 It's possible to instruct the file viewer how to display a file, look
3004 at the
3005 .\"LINK2"
3006 Edit Extension File section
3007 .\"Edit Extension File"
3009 .\"NODE "Internal File Editor"
3010 .SH "Internal File Editor"
3011 The internal file editor is a full\-featured full screen editor.  It can
3012 edit files up to 64 megabytes.  It is possible to edit binary files.
3013 The internal file editor is invoked using
3014 .B F4
3015 if the
3016 .I use_internal_edit
3017 option is set in the initialization file.
3019 The features it presently supports are: block copy, move, delete, cut,
3020 paste; key for key undo; pull\-down menus; file insertion; macro
3021 commands; regular expression search and replace; shift\-arrow text highlighting
3022 (if supported by the terminal); insert\-overwrite toggle; word wrap;
3023 autoindent; tunable tab size; syntax highlighting for various file
3024 types; and an option to pipe text blocks through shell commands like
3025 indent and ispell.
3027 Sections:
3029 .\"LINK2"
3030 Options of editor in ini\-file
3031 .\"Internal File Editor / options"
3033 The editor is very easy to use and requires no tutoring. To see what
3034 keys do what, just consult the appropriate pull\-down menu. Other keys
3035 are: Shift movement keys do text highlighting.
3036 .B Ctrl\-Ins
3037 copies to the file
3038 .B mcedit.clip
3040 .B Shift\-Ins
3041 pastes from mcedit.clip.
3042 .B Shift\-Del
3043 cuts to
3044 .BR mcedit.clip ,
3046 .B Ctrl\-Del
3047 deletes highlighted text. Mouse highlighting also works, and you
3048 can override the mouse as usual by holding down the shift key
3049 while dragging the mouse to let normal terminal mouse highlighting
3050 work.
3052 To define a macro, press
3053 .B Ctrl\-R
3054 and then type out the key
3055 strokes you want to be executed. Press
3056 .B Ctrl\-R
3057 again when finished. You can then assign the macro to any key you
3058 like by pressing that key. The macro is executed when you press
3059 .B Ctrl\-A
3060 and then the assigned key. The macro is also executed if
3061 you press Meta, Ctrl, or Esc and the assigned key, provided that the
3062 key is not used for any other function. Once defined, the macro
3063 commands go into the file
3064 .B ~/.local/share/mc/mcedit/mcedit.macros
3065 You can delete a macro by deleting the
3066 appropriate line in this file.
3068 To change charset of displayed text may use M\-e (Alt\-e).
3069 Recoding is made from selected codepage into system codepage. To
3070 cancel the recoding you may select "<No translation>" in charset
3071 selection dialog.
3073 .B F19
3074 will format the currently highlighted block (plain text or
3075 .B C
3077 .B C++
3078 code or another). This is controlled by the
3079 file
3080 .B %prefix%/share/mc/edit.indent.rc
3081 which is copied to
3082 .B ~/.local/share/mc/mcedit/edit.indent.rc
3083 in your home directory the first time you use it.
3085 The editor also displays non\-us characters (160+). When editing
3086 binary files, you should set
3087 .B display bits
3088 to 7 bits in the options menu to keep the spacing clean.
3090 .\"NODE "Internal File Editor / options"
3091 .SH "Options of editor in ini\-file"
3093 Some editor options of ini\-file are described in this section.
3094 Options are placed in [Midnight\-Commander] section
3096 .I editor_wordcompletion_collect_entire_file
3097 Search autocomplete candidates in entire of file or just from
3098 begin of file to cursor position (0)
3100 .\"NODE "Screen selector"
3101 .SH "Screen selector"
3102 Midnight Commander supports running many internal modules (such as
3103 editor, viewer and diff viewer) simultaneously and switching between
3104 them without closing open files. Using several file managers at a time,
3105 however, is not currently supported.
3107 Let's call each of these modules a screen. There are three ways to
3108 switch between screens, using one of these global shortcuts:
3110 .B Alt\-}
3111 switch to the next screen;
3113 .B Alt\-{
3114 switch to the previous screen;
3116 .B Alt\-`
3117 open a dialog window with the list of currently open screens (or use the
3118 "Screen list" menu item).
3119 .\"NODE "Completion"
3120 .SH "Completion"
3121 Let Midnight Commander type for you.
3123 Attempt to perform completion on the text before current position.  MC
3124 attempts completion treating the text as variable (if the text begins
3125 with
3126 .BR $ ),
3127 username (if the text begins with
3128 .BR ~ ),
3129 hostname (if the text begins with
3130 .BR @ )
3131 or command (if you are on the command line in the position where you
3132 might type a command, possible completions then include shell reserved
3133 words and shell built\-in commands as well) in turn.  If none of these
3134 matches, filename completion is attempted.
3136 Filename, username, variable and hostname completion works on all input
3137 lines, command completion is command line specific.  If the completion
3138 is ambiguous (there are more different possibilities), MC beeps and the
3139 following action depends on the setting of the
3140 .\"LINK2"
3141 Complete: show all
3142 .\"Configuration"
3143 option in the
3144 .\"LINK2"
3145 Configuration
3146 .\"Configuration"
3147 dialog.  If it is enabled, a list of all possibilities pops up next to
3148 the current position and you can select with the arrow keys and
3149 .B Enter
3150 the correct entry.  You can also type the first letters in which the
3151 possibilities differ to move to a subset of all possibilities and
3152 complete as much as possible.  If you press
3153 .B Alt\-Tab
3154 again, only the subset will be shown in the listbox, otherwise the first
3155 item which matches all the previous characters will be highlighted.  As
3156 soon as there is no ambiguity, dialog disappears, but you can hide it by
3157 canceling keys
3158 .BR Esc ,
3159 .B F10
3160 and left and right arrow keys. If
3161 .\"LINK2"
3162 Complete: show all
3163 .\"Configuration"
3164 is disabled, the dialog pops up only if you press
3165 .B Alt\-Tab
3166 for the second time, for the first time MC just beeps.
3168 Apply escaping of
3169 .BR ? ", " * " and " &
3170 symbols (as \fB\\?\fR, \fB\\*\fR, \fB\\&\fR )
3171 in filenames to disallow use them as metasymbols in regular expressions
3172 when substitution is performed in the input line.
3174 .\"NODE "Virtual File System"
3175 .SH "Virtual File System"
3176 Midnight Commander is provided with a code layer to access the file
3177 system; this code layer is known as the virtual file system switch.  The
3178 virtual file system switch allows Midnight Commander to manipulate
3179 files not located on the Unix file system.
3181 Currently, Midnight Commander is packaged with some Virtual File
3182 Systems (VFS): the
3183 .I local
3184 file system, used for accessing the regular Unix file system; the
3185 .IR ftpfs ,
3186 used to manipulate files on remote systems with the FTP protocol; the
3187 .IR tarfs ,
3188 used to manipulate tar and compressed tar files; the
3189 .IR undelfs ,
3190 used to recover deleted files on ext2 file systems (the default file
3191 system for Linux systems),
3192 .I fish
3193 (for manipulating files over shell connections such as rsh and ssh).
3194 If the code was compiled with
3195 .I sftpfs
3196 (for manipulating files over SFTP connections).
3197 If the code was compiled with
3198 .I smbfs
3199 support, you can manipulate files on remote systems with the SMB (CIFS)
3200 protocol.
3202 A generic
3203 .I extfs
3204 (EXTernal virtual File System) is provided in order to easily expand
3205 VFS capabilities using scripts and external software.
3207 The VFS switch code will interpret all of the path names used and will
3208 forward them to the correct file system, the formats used for each one
3209 of the file systems is described later in their own section.
3210 .\"NODE "  FTP File System"
3211 .SH "  FTP File System"
3212 The FTP File System (ftpfs) allows you to manipulate files on remote
3213 machines.  To actually use it, you can use the
3214 .I FTP link
3215 item in the menu or directly change your current directory using the
3216 .I cd
3217 command to a path name that looks like this:
3219 .I ftp://[!][user[:pass]@]machine[:port][remote\-dir]
3222 .IR user ,
3223 .I port
3225 .I remote\-dir
3226 elements are optional.  If you specify the
3227 .I user
3228 element, Midnight Commander will login to the remote machine as that
3229 user, otherwise it will use anonymous login or the login name from the
3230 .I ~/.netrc
3231 file.  The optional
3232 .I pass
3233 element is the password used for the connection.  Using the password in
3234 the VFS directory name is not recommended, because it can appear on the
3235 screen in clear text and can be saved to the directory history.
3237 To enable using FTP proxy, prepend
3238 .B !
3239 (an exclamation sign) to the hostname.
3241 Examples:
3244     ftp://ftp.nuclecu.unam.mx/linux/local
3245     ftp://tsx\-11.mit.edu/pub/linux/packages
3246     ftp://!behind.firewall.edu/pub
3247     ftp://guest@remote\-host.com:40/pub
3248     ftp://miguel:xxx@server/pub
3251 Please check the
3252 .\"LINK2"
3253 Virtual File System
3254 .\"Virtual FS"
3255 dialog box for ftpfs options.
3256 .\"NODE "  Tar File System"
3257 .SH "  Tar File System"
3258 The tar file system provides you with read\-only access to your tar
3259 files and compressed tar files by using the chdir command.  To change
3260 your directory to a tar file, you change your current directory to the
3261 tar file by using the following syntax:
3263 .I /filename.tar/utar://[dir\-inside\-tar]
3265 The mc.ext file already provides a shortcut for tar files, this means
3266 that usually you just point to a tar file and press return to enter
3267 into the tar file, see the
3268 .\"LINK2"
3269 Edit Extension File
3270 .\"Edit Extension File"
3271 section for details on how this is done.
3273 Examples:
3276     mc\-3.0.tar.gz/utar://mc\-3.0/vfs
3277     /ftp/GCC/gcc\-2.7.0.tar/utar://
3280 The latter specifies the full path of the tar archive.
3281 .\"NODE "  FIle transfer over SHell filesystem"
3282 .SH "  FIle transfer over SHell filesystem"
3283 The fish file system is a network based file system that allows you to
3284 manipulate the files in a remote machine as if they were local. To use
3285 this, the other side has to either run fish server, or has to have
3286 bash\-compatible shell.
3288 To connect to a remote machine, you just need to chdir
3289 into a special directory which name is in the following
3290 format:
3292 .I sh://[user@]machine[:options]/[remote\-dir]
3295 .I user,
3296 .I options
3298 .I remote\-dir
3299 elements are optional.  If you specify the
3300 .I user
3301 element, Midnight Commander will try to login on the remote
3302 machine as that user, otherwise it will use your login name.
3304 The available
3305 .I options
3306 are:
3308   'C' \- use compression;
3309   'r' \- use rsh instead of ssh;
3310   port \- specify the port used by remote server.
3312 If the
3313 .I remote\-dir
3314 element is present, your current directory on the remote machine will be
3315 set to this one.
3317 Examples:
3320     sh://onlyrsh.mx:r/linux/local
3321     sh://joe@want.compression.edu:C/private
3322     sh://joe@noncompressed.ssh.edu/private
3323     sh://joe@somehost.ssh.edu:2222/private
3325 .\"NODE "  SFTP (SSH File Transfer Protocol) filesystem"
3326 .SH "  SFTP (SSH File Transfer Protocol) filesystem"
3327 The SFTP file system is a network based file system that allows you to
3328 manipulate the files in a remote machine as if they were local.
3330 To connect to a remote machine, you just need to chdir
3331 into a special directory which name is in the following
3332 format:
3334 .I sftp://[user@]machine:[port]/[remote\-dir]
3337 .I user,
3338 .I port
3340 .I remote\-dir
3341 elements are optional.  If you specify the
3342 .I user
3343 element, Midnight Commander will try to login on the remote
3344 machine as that user, otherwise it will use your login name.
3345 .I port
3346 \- specify the port used by remote server (22 by default).
3347 If the
3348 .I remote\-dir
3349 element is present, your current directory on the remote machine will be
3350 set to this one.
3352 Examples:
3355     sftp://onlyrsh.mx/linux/local
3356     sftp://joe:password@want.compression.edu/private
3357     sftp://joe@noncompressed.ssh.edu/private
3358     sftp://joe@somehost.ssh.edu:2222/private
3360 .\"NODE "  Undelete File System"
3361 .SH "  Undelete File System"
3362 On Linux systems, if you asked configure to use the ext2fs undelete
3363 facilities, you will have the undelete file system available.
3364 Recovery of deleted files is only available on ext2 file systems.  The
3365 undelete file system is just an interface to the ext2fs library to
3366 retrieve all of the deleted files names on an ext2fs and provides and
3367 to extract the selected files into a regular partition.
3369 To use this file system, you have to chdir into the special file name
3370 formed by the "undel://" prefix and the file name where the actual
3371 file system resides.
3373 For example, to recover deleted files on the second partition of the
3374 first SCSI disk on Linux, you would use the following path name:
3377     undel://sda2
3380 It may take a while for the undelfs to load the required information
3381 before you start browsing files there.
3382 .\"NODE "  SMB File System"
3383 .SH "  SMB File System"
3384 The smbfs allows you to manipulate files on remote machines with SMB
3385 (or CIFS) protocol.  These include Windows for Workgroups,
3386 Windows 9x/ME/XP, Windows NT, Windows 2000 and Samba.
3387 To actually use it, you may try to use the panel command "SMB link..."
3388 (accessible from the menubar) or you may directly change your current
3389 directory to it using the cd command to a path name that looks like this:
3391 .I smb://[user@]machine[/service][/remote\-dir]
3394 .IR user ,
3395 .I service
3397 .I remote\-dir
3398 elements are optional.
3400 .IR user ,
3401 .I domain
3403 .I password
3404 can be specified in an input dialog.
3406 Examples:
3409     smb://machine/Share
3410     smb://other_machine
3411     smb://guest@machine/Public/Irlex
3413 .\"NODE "  EXTernal File System"
3414 .SH "  EXTernal File System"
3415 .B extfs
3416 allows you to integrate numerous features and file types into GNU Midnight
3417 Commander in an easy way, by writing scripts.
3419 Extfs filesystems can be divided into two categories:
3421 1. Stand\-alone filesystems, which are not associated with any existing
3422 file.  They represent certain system\-wide data as a directory tree.
3423 You can invoke them by typing
3424 .RI ' "cd fsname://" '
3425 where fsname is an extfs short name (see below).  Examples of such
3426 filesystems include audio (list audio tracks on the CD) or apt (list of
3427 all Debian packages in the system).
3429 For example, to list CD\-Audio tracks on your CD\-ROM drive, type
3432   cd audio://
3435 2. 'Archive' filesystems (like rpm, patchfs and more), which represent
3436 contents of a file as a directory tree.  It can consist of 'real' files
3437 compressed in an archive (urar, rpm) or virtual files, like messages
3438 in a mailbox (mailfs) or parts of a patch (patchfs).  To access such
3439 filesystems
3440 .RI ' fsname:// '
3441 should be appended to the archive name.  Note that the archive itself
3442 can be on another vfs.
3444 For example, to list contents of a zip archive documents.zip type
3447   cd documents.zip/uzip://
3450 In many aspects, you could treat extfs like any other directory.  For
3451 instance, you can add it to the hotlist or change to it from directory
3452 history.  An important limitation is that you cannot invoke shell
3453 commands inside extfs, just like any other non\-local VFS.
3455 Common extfs scripts included with Midnight Commander are:
3457 .B a
3458 access 'A:' DOS/Windows diskette
3459 .RI ( "cd a://" ).
3461 .B apt
3462 front end to Debian's APT package management system
3463 .RI ( "cd apt://" ).
3465 .B audio
3466 audio CD ripping and playing
3467 .RI ( "cd audio://"
3469 .IR "cd device/audio://" ).
3471 .B bpp
3472 package of Bad Penguin GNU/Linux distribution
3473 .RI ( "cd file.bpp/bpp://" ).
3475 .B deb
3476 package of Debian GNU/Linux distribution
3477 .RI ( "cd file.deb/deb://" ).
3479 .B dpkg
3480 Debian GNU/Linux installed packages
3481 .RI ( "cd deb://" ).
3483 .B hp48
3484 view and copy files to/from a HP48 calculator
3485 .RI ( "cd hp48://" ).
3487 .B lslR
3488 browsing of lslR listings as found on many FTPs
3489 .RI ( "cd filename/lslR://" ).
3491 .B mailfs
3492 mbox\-style mailbox files support
3493 .RI ( "cd mailbox/mailfs://" ).
3495 .B patchfs
3496 extfs to handle unified and context diffs
3497 .RI ( "cd filename/patchfs://" ).
3499 .B rpm
3500 RPM package
3501 .RI ( "cd filename/rpm://" ).
3503 .B rpms
3504 RPM database management
3505 .RI ( "cd rpms://" ).
3507 .B ulha, urar, uzip, uzoo, uar, uha
3508 archivers
3509 .RI ( "cd archive/xxxx://"
3510 where xxxx is one of:
3511 .IR ulha ,
3512 .IR urar ,
3513 .IR uzip ,
3514 .IR uzoo ,
3515 .IR uar ,
3516 .IR uha ).
3518 You could bind file type/extension to specified extfs as described in the
3519 .\"LINK2"
3520 Edit Extension File
3521 .\"Edit Extension File"
3522 section.  Here is an example entry for Debian packages:
3525   regex/\.deb$
3526           Open=%cd %p/deb://
3528 .\"NODE "Colors"
3529 .SH "Colors"
3530 Midnight Commander will try to detect if your terminal supports
3531 color using the terminal database and your terminal name.  Sometimes
3532 it gets confused, so you may force color mode or disable color mode
3533 using the \-c and \-b flag respectively.
3535 If the program is compiled with the Slang screen manager instead of
3536 ncurses, it will also check the variable
3537 .B COLORTERM,
3538 if it is set, it has the same effect as the \-c flag.
3540 You may specify terminals that always force color mode
3541 by adding the
3542 .I color_terminals
3543 variable to the Colors section of the initialization file.  This will
3544 prevent Midnight Commander from trying to detect if your terminal
3545 supports color.  Example:
3548 [Colors]
3549 color_terminals=linux,xterm
3550 color_terminals=terminal\-name1,terminal\-name2...
3553 The program can be compiled with both ncurses and slang, ncurses does
3554 not provide a way to force color mode: ncurses uses just the
3555 information in the terminal database.
3557 Midnight Commander provides a way to change the default colors.
3558 Currently the colors are configured using the environment variable
3559 .B MC_COLOR_TABLE
3560 or the Colors section in the initialization file.
3562 In the Colors section, the default color map is loaded from the
3563 .I base_color
3564 variable.  You can specify an alternate color map for a terminal by
3565 using the terminal name as the key in this section.  Example:
3568 [Colors]
3569 base_color=
3570 xterm=menu=magenta:marked=,magenta:markselect=,red
3573 The format for the color definition is:
3576   <keyword>=<fgcolor>,<bgcolor>,<attributes>:<keyword>=...
3579 The colors are optional, and the keywords are: normal, selected, disabled, marked,
3580 markselect, errors, input, inputmark, inputunchanged, commandlinemark,
3581 reverse, gauge, header, inputhistory, commandhistory. Button bar colors are:
3582 bbarhotkey, bbarbutton. Status bar color: statusbar. Menu colors are: menunormal,
3583 menusel, menuhot, menuhotsel, menuinactive. Dialog colors are: dnormal, dfocus,
3584 dhotnormal, dhotfocus, dtitle. Error dialog colors are: errdfocus, errdhotnormal,
3585 errdhotfocus, errdtitle.  Help colors are: helpnormal, helpitalic, helpbold,
3586 helplink, helpslink, helptitle.  Viewer colors are: viewnormal, viewbold,
3587 viewunderline, viewselected. Editor colors are: editnormal, editbold, editmarked,
3588 editwhitespace, editlinestate. Popup menu colors are: pmenunormal, pmenusel,
3589 pmenutitle.
3591 .I header
3592 determines the color of panel header, the line that contains column titles
3593 and sort mode indicator.
3595 .I input
3596 determines the color of input lines used in query dialogs.
3598 .I gauge
3599 determines the color of the filled part of the progress bar (gauge),
3600 which is used to show the user the progress of file operations, such as
3601 copying.
3603 .I disabled
3604 determines the color of the widget that cannot be selected.
3606 The dialog boxes use the following colors:
3607 .I dnormal
3608 is used for the normal text,
3609 .I dfocus
3610 is the color used for the currently selected component,
3611 .I dhotnormal
3612 is the color used to differentiate the hotkey color in normal
3613 components, whereas the
3614 .I dhotfocus
3615 color is used for the highlighted color in the currently selected
3616 component.
3618 Menus use the same scheme but uses the menunormal, menusel, menuhot, menuhotsel
3619 and menuinactive tags instead.
3621 Help uses the following colors:
3622 .I helpnormal
3623 is used for normal text,
3624 .I helpitalic
3625 is used for text which is emphasized in italic in the manual page,
3626 .I helpbold
3627 is used for text which is emphasized in bold in the manual page,
3628 .I helplink
3629 is used for not selected hyperlinks and
3630 .I helpslink
3631 is used for selected hyperlink.
3633 Popup menu uses following colors:
3634 .I pmenunormal
3635 is used for non\-selected menu items and as a main color of popup menu window,
3636 .I pmenusel
3637 is used for selected menu item,
3638 .I pmenutitle
3639 is used for popup menu title.
3641 The possible colors are: black, gray, red, brightred, green,
3642 brightgreen, brown, yellow, blue, brightblue, magenta, brightmagenta,
3643 cyan, brightcyan, lightgray and white. And there is a special keyword
3644 for transparent background. It is 'default'. The 'default' can only be
3645 used for background color. Another special keyword "base" means mc's main
3646 colors.  When 256 colors are available, they can be specified either as
3647 color16 to color255, or as rgb000 to rgb555 and gray0 to gray23. Example:
3650 [Colors]
3651 base_color=normal=white,default:marked=magenta,default
3654 Attributes can be any of bold, italic, underline, reverse and blink, appended by a
3655 plus sign if more than one are desired.  The special word "none" means no
3656 attributes, without attempting to fall back to base_color.  Example:
3659 menuhotsel=yellow;black;bold+underline
3662 .\"NODE "Skins"
3663 .SH "Skins"
3664 You can change the appearance of Midnight Commander.
3665 To do this, you must specify a file that contain descriptions of colors
3666 and lines to draw boxes. Redefining of the colors is entirely compatible
3667 with the assignment of colors, as described in Section
3668 .\"LINK2"
3669 Colors\&.
3670 .\"Colors"
3672 If your skin contains any true\-color definitions, you should define
3673 the 'truecolors' key set to TRUE value in [skin] section. If true\-color
3674 is not used but 256\-color is, you should define '256colors' instead.
3676 A skin\-file is searched on the following algorithm (to the first one found):
3679 1) command line option
3680 .B \-S <skin>
3682 .B \-\-skin=<skin>
3684 2) Environment variable
3685 .B MC_SKIN
3687 3) Parameter
3688 .B skin
3689 in section
3690 .B [Midnight\-Commander]
3691 in config file.
3693 4) File
3694 .B %sysconfdir%/mc/skins/default.ini
3696 5) File
3697 .B %prefix%/share/mc/skins/default.ini
3700 Command line option, environment variable and parameter in config file may
3701 contain the absolute path to the skin\-file (with the extension \.ini
3702 or without it). Search of skin\-file will occur in (to the first one found):
3705 .B ~/.local/share/mc/skins/
3708 .B %sysconfdir%/mc/skins/
3711 .B %prefix%/share/mc/skins/
3715 For getting extended info, refer to:
3717 .\"LINK2"
3718 Description of section and parameters
3719 .\"Skins sections"
3721 .\"LINK2"
3722 Color pair definitions
3723 .\"Skins colors"
3725 .\"LINK2"
3726 Color and attribute aliases
3727 .\"Skins aliases"
3729 .\"LINK2"
3730 Draw lines
3731 .\"Skins lines"
3733 .\"LINK2"
3734 Compatibility
3735 .\"Skins oldcolors"
3738 .\"NODE "  Skins sections"
3739 .SH "  Description of section and parameters"
3741 Section
3742 .B [skin]
3743 contain metainfo for skin\-file. Parameter
3744 .I description
3745 contain short text about skin.
3748 Section
3749 .B [filehighlight]
3750 contain descriptions of color pairs for filenames highlighting.
3751 Name of parameters must be equal to names of sections into
3752 filehighlight.ini file.
3754 .\"LINK2"
3755 Filenames Highlight
3756 .\"Filenames Highlight"
3757 for getting more info.
3760 Section
3761 .B [core]
3762 describes the elements that are used everywhere.
3764 .I _default_
3765 Default color pair. Used in all other sections if they not contain
3766 color definitions
3768 .I selected
3769 cursor
3771 .I marked
3772 selected data
3774 .I markselect
3775 cursor on selected data
3777 .I gauge
3778 color of the filled part of the progress bar
3780 .I input
3781 color of input lines used in query dialogs
3783 .I inputmark
3784 color of input selected text
3786 .I inputunchanged
3787 color of input text before first modification or cursor movement
3789 .I commandlinemark
3790 color of selected text in command line
3792 .I reverse
3793 reverse color
3795 Section
3796 .B [dialog]
3797 describes the elements that are placed on dialog windows (except error dialogs).
3799 .I _default_
3800 Default color for this section. Used [core]._default_ if not specified
3802 .I dfocus
3803 Color of active element (in focus)
3805 .I dhotnormal
3806 Color of hotkeys
3808 .I dhotfocus
3809 Color of hotkeys in focused element
3812 Section
3813 .B [error]
3814 describes the elements that are placed on error dialog windows
3816 .I _default_
3817 Default color for this section. Used [core]._default_ if not specified
3819 .I errdhotnormal
3820 Color of hotkeys
3822 .I errdhotfocus
3823 Color of hotkeys in focused element
3826 Section
3827 .B [menu]
3828 describes the elements that are placed in menu. This section describes
3829 system menu (called by F9) and user\-defined menus (called by F2 in panels
3830 and by F11 in editor).
3832 .I _default_
3833 Default color for this section. Used [core]._default_ if not specified
3835 .I entry
3836 Color of menu items
3838 .I menuhot
3839 Color of menu hotkeys
3841 .I menusel
3842 Color of active menu item (in focus)
3844 .I menuhotsel
3845 Color of menu hotkeys in focused menu item
3847 .I menuinactive
3848 Color of inactive menu
3851 Section
3852 .B [help]
3853 describes the elements that are placed on help window.
3855 .I _default_
3856 Default color for this section. Used [core]._default_ if not specified
3858 .I helpitalic
3859 Color pair for element with
3860 .B italic
3861 attribute
3863 .I helpbold
3864 Color pair for element with
3865 .B bold
3866 attribute
3868 .I helplink
3869 Color of links
3871 .I helpslink
3872 Color of active link (on focus)
3875 Section
3876 .B [editor]
3877 describes the colors of elements placed in editor.
3879 .I _default_
3880 Default color for this section. Used [core]._default_ if not specified
3882 .I editbold
3883 Color pair for element with
3884 .B bold
3885 attribute
3887 .I editmarked
3888 Color of selected text
3890 .I editwhitespace
3891 Color of tabs and trailing spaces highlighting
3893 .I editlinestate
3894 Color for line state area
3897 Section
3898 .B [viewer]
3899 describes the colors of elements placed in viewer.
3901 .I viewunderline
3902 Color pair for element with
3903 .B underline
3904 attribute
3906 .\"NODE "  Skins colors"
3907 .SH "  Color pair definitions"
3908 Any parameter in skin\-file contain definition of color pair.
3910 Color pairs described as two colors and the optional attributes
3911 separated by ';'. First field sets the foreground color, second
3912 field sets background color, third field sets the attributes.
3913 Any of the fields may be omitted, in this case value will be
3914 taken from default color pair (global color pair or from default
3915 color pair of this section).
3917 Example:
3920 [core]
3921     # green on black
3922     _default_=green;black
3923     # green (default) on blue
3924     selected=;blue
3925     # yellow on black (default)
3926     # underlined yellow on black (default)
3927     marked=yellow;;underline
3931 Possible colors (names) and attributes are described in
3932 .\"LINK2"
3933 Colors\&.
3934 .\"Colors"
3935 section.
3937 .\"NODE "  Skins aliases"
3938 .SH "  Color and attribute aliases"
3939 This optional section might define aliases for single colors (not color pairs)
3940 as well as combination of attributes; in other words, for semicolon\-separated
3941 fragments of parameters. Aliases can refer to other aliases as long as they
3942 don't form a loop.
3944 Example:
3947 [aliases]
3948     myfavfg=green
3949     myfavbg=black
3950     myfavattr=bold+italic
3951 [core]
3952     _default_=myfavfg;myfavbg;myfavattr
3955 .\"NODE "  Skins lines"
3956 .SH "  Draw lines"
3957 Lines sets in section
3958 .B [Lines]
3959 into skin\-file. By default single lines are used, but you may redefine
3960 to usage of any utf\-8 symbols (like to lines, for example).
3962 .I WARNING!!!
3963 When you build Midnight Commander with the Ncurses screen library
3964 usage of drawing lines is limited!
3965 Possible only drawing a single lines.
3966 For all questions and comments please contact the developers of Ncurses.
3969 Descriptions of parameters
3970 .BR [Lines] :
3972 .I lefttop
3973 left\-top line fragment.
3975 .I righttop
3976 right\-top line fragment.
3978 .I centertop
3979 down branch of horizontal line
3981 .I centerbottom
3982 up branch of horizontal line
3984 .I leftbottom
3985 left\-bottom line fragment
3987 .I rightbottom
3988 right\-bottom line fragment
3990 .I leftmiddle
3991 right branch of vertical line
3993 .I rightmiddle
3994 left branch of vertical line
3996 .I centermiddle
3997 cross of lines
3999 .I horiz
4000 horizontal line
4002 .I vert
4003 vertical line
4005 .I thinhoriz
4006 thin horizontal line
4008 .I thinvert
4009 thin vertical line
4012 .\"NODE "  Skins oldcolors"
4013 .SH "  Compatibility"
4015 Appointment of color  by skin\-files fully compatible with
4016 the appointment of the colors described in
4017 .\"LINK2"
4018 Colors\&.
4019 .\"Colors"
4020 section.
4022 In this case, reassignment of colors has priority over the skin file and is
4023 complementary.
4025 .\"NODE "Filenames Highlight"
4026 .SH "Filenames Highlight"
4027 Section [filehighlight] in current skin\-file contains key names as
4028 highlight groups and values as color pairs. Color pairs is documented
4030 .\"LINK2"
4031 Skins
4032 .\"Skins"
4033 section.
4035 Rules of filenames highlight are placed in %prefix%/share/mc/filehighlight.ini file
4036 (~/.config/mc/filehighlight.ini).
4037 Name of section in this file must be equal to parameters names in
4038 [filehighlight] section (in current skin\-file).
4040 Keys in these groups are:
4042 .I type
4043 file type. If present, all other options are ignored.
4045 .I regexp
4046 regular expression. If present, 'extensions' option is ignored.
4048 .I extensions
4049 list of extensions of files. Separated by ';' sign.
4051 .I extensions_case
4052 (make sense only with 'extensions' parameter) make 'extensions'
4053 rule case sensitive (true) or not (false).
4055 `type' key may have values:
4057 \- FILE (all files)
4058   \- FILE_EXE
4059 \- DIR (all directories)
4060   \- LINK_DIR
4061 \- LINK (all links except stale link)
4062   \- HARDLINK
4063   \- SYMLINK
4064 \- STALE_LINK
4065 \- DEVICE (all device files)
4066   \- DEVICE_BLOCK
4067   \- DEVICE_CHAR
4068 \- SPECIAL (all special files)
4069   \- SPECIAL_SOCKET
4070   \- SPECIAL_FIFO
4071   \- SPECIAL_DOOR
4075 .\"NODE "Special Settings"
4076 .SH "Special Settings"
4077 Most of Midnight Commander settings can be changed from the
4078 menus. However, there are a small number of settings which can only be
4079 changed by editing the setup file.
4081 These variables may be set in your ~/.config/mc/ini file:
4083 .I clear_before_exec
4084 By default, Midnight Commander clears the screen before executing a
4085 command.  If you would prefer to see the output of the command at the
4086 bottom of the screen, edit your ~/.config/mc/ini file and change the value of
4087 the field clear_before_exec to 0.
4089 .I confirm_view_dir
4090 If you press F3 on a directory, normally MC enters that directory.  If
4091 this flag is set to 1, then MC will ask for confirmation before changing
4092 the directory if you have files tagged.
4094 .I ftpfs_retry_seconds
4095 This value is the number of seconds Midnight Commander will wait
4096 before attempting to reconnect to an FTP server that has denied the
4097 login.  If the value is zero, the login will no be retried.
4099 .I max_dirt_limit
4100 Specifies how many screen updates can be skipped at most in the internal
4101 file viewer.  Normally this value is not significant, because the code
4102 automatically adjusts the number of updates to skip according to the
4103 rate of incoming keystrokes.  However, on very slow machines or
4104 terminals with a fast keyboard auto repeat, a big value can make screen
4105 updates too jumpy.
4107 It seems that setting max_dirt_limit to 10 causes the best behavior,
4108 and that is the default value.
4110 .I mouse_move_pages_viewer
4111 Controls if scrolling with the mouse is done by pages or line by line
4112 on the internal file viewer.
4114 .I only_leading_plus_minus
4115 Allow special treatment for '+', '\-', '*' in the command line (select,
4116 unselect, reverse selection) only if the command line is empty.  You
4117 don't need to quote those characters in the middle of the command line.
4118 On the other hand, you cannot use them to change selection when the
4119 command line is not empty.
4121 .I show_output_starts_shell
4122 This variable only works if you are not using the subshell support.
4123 When you use the C\-o keystroke to go back to the user screen, if this
4124 one is set, you will get a fresh shell.  Otherwise, pressing any key
4125 will bring you back to Midnight Commander.
4127 .I timeformat_recent
4128 Change the time format used to display dates less than 6 months from
4129 now.
4130 See strftime or date man page for the format specification. If this
4131 option is absent, default timeformat is used.
4133 .I timeformat_old
4134 Change the time format used to display  dates older than 6 months from
4135 now or for dates in the future.
4136 See strftime or date man page for the format specification. If this
4137 option is absent, default timeformat is used.
4139 .I torben_fj_mode
4140 If this flag is set, then the home and end keys will work slightly
4141 different on the panels, instead of moving the selection to the first
4142 and last files in the panels, they will act as follows:
4144 The home key will: Go up to the middle line, if below it; else go to the
4145 top line unless it is already on the top line, in this case it will go
4146 to the first file in the panel.
4148 The end key has a similar behavior: Go down to the middle line, if over
4149 it; else go to the bottom line unless you already are at the bottom
4150 line, in such case it will move the selection to the last file name in
4151 the panel.
4153 .I use_file_to_guess_type
4154 If this variable is on (the default) it will spawn the file command to
4155 match the file types listed on the
4156 .\"LINK2"
4157 mc.ext file\&.
4158 .\"Edit Extension File"
4160 .I xtree_mode
4161 If this variable is on (default is off) when you browse the file system
4162 on a Tree panel, it will automatically reload the other panel with the
4163 contents of the selected directory.
4165 .I fish_directory_timeout
4166 This variable holds the lifetime of a directory cache entry in seconds. The
4167 default value is 900 seconds.
4169 .I clipboard_store
4170 This variable contains path (with options) to the external clipboard
4171 utility like 'xclip' to read text into X selection from file.
4172 For example:
4175 clipboard_store=xclip \-i
4178 .I clipboard_paste
4179 This variable contains path (with options) to the external clipboard
4180 utility like 'xclip' to print the selection to standard out.
4181 For example:
4184 clipboard_paste=xclip \-o
4187 .I autodetect_codeset
4188 This option allows use the `enca' command to autodetect codeset of text files
4189 in internal viewer and editor. List of valid values can be obtain by the
4190 `enca \-\-list languages | cut \-d : \-f1' command. Option must be located
4191 in the [Misc] section.
4193 For example:
4196 autodetect_codeset=russian
4198 .\"NODE "Parameters for external editor or viewer"
4199 .SH "Parameters for external editor or viewer"
4200 Midnight Commander provides a way for specify an options for external editors
4201 and viewers. Midnight Commander tries to search the
4202 "[External editor or viewer parameters]" section in the system initialization file
4203 (the mc.lib file located in Midnight Commander's library directory)
4204 and then in the ~/.config/mc/ini file. The option name should be equal to the name
4205 (full pathname) of external editor or viewer. The option value can contain following
4206 variables:
4208 .I %filename
4209 The filename to edit/view.
4211 .I %lineno
4212 The start line in the opening file.
4214 For example:
4217 [External editor or viewer parameters]
4218     vi=%filename +%lineno
4219     joe=%filename +%lineno
4220     more=%filename +%lineno
4223 Start line is passed to the external editor/viewer only if it is called from the
4224 .\"LINK2"
4225 Find file
4226 .\"Find File"
4227 results window.
4229 If external editor/viewer is launched via F4/F3 keys, MC hopes that program
4230 (at least "joe", but probably others too) has an own feature that by default
4231 opens the file where it was last open. MC doesn't prevent external editor/viewer
4232 to save and restore position in opened files.
4233 .\"NODE "Terminal databases"
4234 .SH "Terminal databases"
4235 Midnight Commander provides a way to fix your system terminal
4236 database without requiring root privileges. Midnight Commander
4237 searches in the system initialization file (the mc.lib file located in
4238 Midnight Commander's library directory) and in the 
4239 ~/.config/mc/ini file for the section 
4240 "terminal:your\-terminal\-name" and then for the section
4241 "terminal:general", each line of the section contains a key symbol that
4242 you want to define, followed by an equal sign and the definition for the
4243 key.  You can use the special \\e form to represent the escape character
4244 and the ^x to represent the control\-x character.
4246 The possible key symbols are:
4249 f0 to f20     Function keys f0\-f20
4250 bs            backspace
4251 home          home key
4252 end           end key
4253 up            up arrow key
4254 down          down arrow key
4255 left          left arrow key
4256 right         right arrow key
4257 pgdn          page down key
4258 pgup          page up key
4259 insert        the insert character
4260 delete        the delete character
4261 complete      to do completion
4264 For example, to define the key insert to be the Escape + [ + O + p, you
4265 set this in the ini file:
4268 insert=\\e[Op
4272 Also now you can use
4273 .I extended learn keys.
4274 For example:
4277     ctrl\-alt\-right=\\e[[1;6C
4278     ctrl\-alt\-left=\\e[[1;6D
4282 This means that ctrl+alt+left sends a \\e[[1;6D escape sequence
4283 and therefore Midnight Commander interprets "\\e[[1;6D" as Ctrl\-Alt\-Left.
4287 .I complete
4288 key symbol represents the escape sequences used to invoke the completion
4289 process, this is invoked with Alt\-tab, but you can define other keys to do
4290 the same work (on those keyboard with tons of nice and unused keys
4291 everywhere).
4292 .SH ""
4293 .\"NODE "FILES"
4294 .SH "FILES"
4295 Full paths below may vary between installations.  They are also affected
4296 by the
4297 .BR MC_DATADIR
4298 environment variable. If it's set, its value is used instead of
4299 %prefix%/share/mc in the paths below.
4301 .I %prefix%/share/mc/help/mc.hlp
4303 The help file for the program.
4305 .I %prefix%/share/mc/mc.ext
4307 The default system\-wide extensions file.
4309 .I ~/.config/mc/mc.ext
4311 User's own extension, view configuration and edit configuration
4312 file.  They override the contents of the system wide files if present.
4314 .I %prefix%/share/mc/mc.ini
4316 The default system\-wide setup for Midnight Commander, used only if
4317 the user doesn't have his own ~/.config/mc/ini file.
4319 .I %prefix%/share/mc/mc.lib
4321 Global settings for Midnight Commander. Settings in this file
4322 affect all users, whether they have ~/.config/mc/ini or not.  Currently, only
4323 .\"LINK2"
4324 terminal settings
4325 .\"Terminal databases"
4326 are loaded from mc.lib.
4328 .I ~/.config/mc/ini
4330 User's own setup. If this file is present then the setup is loaded
4331 from here instead of the system\-wide startup file.
4333 .I %prefix%/share/mc/hints/mc.hint
4335 This file contains the hints displayed by the program.
4337 .I %prefix%/share/mc/mc.menu
4339 This file contains the default system\-wide applications menu.
4341 .I ~/.config/mc/menu
4343 User's own application menu. If this file is present it is used instead
4344 of the system\-wide applications menu.
4346 .I ~/.cache/mc/Tree
4348 The directory list for the directory tree and tree view features.
4350 .I ~/.local/share/mc.menu
4352 Local user\-defined menu. If this file is present, it is used instead of
4353 the home or system\-wide applications menu.
4355 To change default root directory of MC, you can use
4356 .BR MC_PROFILE_ROOT
4357 environment variable. The value of MC_PROFILE_ROOT must be an absolute path.
4358 If MC_PROFILE_ROOT is unset or empty, HOME variable is used. If HOME is unset
4359 or empty, MC directories are get from GLib library.
4360 .\"SKIP_SECTION"
4361 .SH "LICENSE"
4362 This program is distributed under the terms of the GNU General Public
4363 License as published by the Free Software Foundation. See the built\-in
4364 help for details on the License and the lack of warranty.
4365 .\"NODE "AVAILABILITY"
4366 .SH "AVAILABILITY"
4367 The latest version of this program can be found at
4368 http://ftp.midnight\-commander.org/.
4369 .\"NODE "SEE ALSO"
4370 .SH "SEE ALSO"
4371 ed(1), gpm(1), terminfo(1), view(1), sh(1), bash(1),
4372 tcsh(1), zsh(1).
4375 Midnight Commander's page on the World Wide Web:
4376         http://www.midnight\-commander.org/
4378 .\"NODE "AUTHORS"
4379 .SH "AUTHORS"
4380 Authors and contributors are listed in the AUTHORS file in the source
4381 distribution.
4382 .\"NODE "BUGS"
4383 .SH "BUGS"
4384 See the file TODO in the distribution for information on what remains to
4385 be done.
4387 If you want to report a problem with the program, please create bugreport
4388 at http://www.midnight\-commander.org/.
4390 Provide a detailed description of the bug, the version of the program
4391 you are running
4392 .RI ( "mc \-V"
4393 displays this information), the operating system you are running the
4394 program on.  If the program crashes, we would appreciate a stack trace.