2 .TH MC 1 "@DATE_OF_MAN_PAGE@" "MC Version @DISTR_VERSION@" "GNU Midnight Commander"
5 mc \- Visual shell for Unix\-like systems.
9 [\-abcCdfhPstuUVx] [\-l log] [dir1 [dir2]] [\-e [file]] [\-v file]
12 GNU Midnight Commander is a directory browser/file manager for
13 Unix\-like operating systems.
18 .I \-a, \-\-stickchars
19 Disable usage of graphic characters for line drawing.
22 Force black and white display.
25 Force color mode, please check the section
31 .I \-C arg, \-\-colors=arg
32 Specify a different color set in the command line. The format of arg is
40 Specify a name of skin in the command line. Technology of skins is
48 Disable mouse support.
50 .I \-e [file], \-\-edit[=file]
51 Start the internal editor. If the file is specified, open it on
56 Display the compiled\-in search paths for Midnight Commander files.
58 .I \-F, \-\-datadir\-info
59 Display extended info about compiled\-in paths for
62 .I \-\-configure\-options
63 Display configure options.
66 Reset softkeys to their default from the termcap/terminfo
67 database. Only useful on HP terminals when the function keys don't work.
70 Specify a name of keymap file in the command line.
73 Don't load key bindings from any file, use default hardcoded keys.
75 .I \-l file, \-\-ftplog=file
76 Save the ftpfs dialog with the server in file.
78 .I \-P file, \-\-printwd=file
79 Print the last working directory to the specified file. This option is
80 not meant to be used directly. Instead, it's used from a special shell
81 script that automatically changes the current directory of the shell to
82 the last directory the Midnight Commander was in. Source the file
83 .B @prefix@/share/mc/bin/mc.sh
84 (bash and zsh users) or
85 .B @prefix@/share/mc/bin/mc.csh
86 (tcsh users) respectively to define
88 as an alias to the appropriate shell script.
91 Set alternative mode drawing of frameworks.
92 If the section [Lines] is not filled, the symbol for the pseudographics
93 frame is a space, otherwise the frame characters are taken from follow params.
95 .B You can redefine the following variables:
125 default horizontal line
128 default vertical line
137 Used only if the code was compiled with Slang and terminfo: it makes
138 the Midnight Commander use the value of the
140 variable for the terminal information instead of the information on
141 the system wide terminal database
143 .I \-u, \-\-nosubshell
144 Disable use of the concurrent shell (only makes sense if the Midnight
145 Commander has been built with concurrent shell support).
148 Enable use of the concurrent shell support (only makes sense if the
149 Midnight Commander was built with the subshell support set as an
152 .I \-v file, \-\-view=file
153 Start the internal viewer to view the specified file. See also
157 Display the version of the program.
160 Force xterm mode. Used when running on xterm\-capable terminals (two
161 screen modes, and able to send mouse escape sequences).
164 Force a "normal tracking" mouse mode. Used when running on
165 xterm\-capable terminals (tmux/screen).
167 If specified, the first path name is the directory to show in the
168 selected panel; the second path name is the directory to be shown in
172 The screen of the Midnight Commander is divided into four parts.
173 Almost all of the screen space is taken up by two directory panels.
174 By default, the second line from the bottom of the screen is the
175 shell command line, and the bottom line shows the function key labels.
176 The topmost line is the
180 The menu bar line may not be visible, but appears if you click the
181 topmost line with the mouse or press the F9 key.
183 The Midnight Commander provides a view of two directories at the same
184 time. One of the panels is the current panel (a selection bar is in
185 the current panel). Almost all operations take place on the current
186 panel. Some file operations like Rename and Copy by default use the
187 directory of the unselected panel as a destination (don't worry, they
188 always ask you for confirmation first). For more information, see the
196 .\"Left and Right Menus"
202 You can execute system commands from the Midnight Commander by simply
203 typing them. Everything you type will appear on the shell command line,
204 and when you press Enter the Midnight Commander will execute the
205 command line you typed; read the
208 .\"Shell Command Line"
213 sections to learn more about the command line.
214 .\"NODE "Mouse Support"
216 The Midnight Commander comes with mouse support. It is activated
217 whenever you are running on an
219 terminal (it even works if you take a telnet, ssh or rlogin connection to
220 another machine from the xterm) or if you are running on a Linux
223 mouse server running.
225 When you left click on a file in the directory panels, that file is
226 selected; if you click with the right button, the file is marked (or
227 unmarked, depending on the previous state).
229 Double\-clicking on a file will try to execute the command if it is
230 an executable program; and if the
233 .\"Extension File Edit"
234 has a program specified for the file's extension, the specified
237 Also, it is possible to execute the commands assigned to the function
238 key labels by clicking on them.
240 The default auto repeat rate for the mouse buttons is 400
241 milliseconds. This may be changed to other values by editing the
245 file and changing the
249 If you are running the Midnight Commander with the mouse support, you
250 can get the default mouse behavior (cutting and pasting text) by holding
255 Some commands in the Midnight Commander involve the use of the
257 (sometimes labeled CTRL or CTL) and the
259 (sometimes labeled ALT or even Compose) keys. In this manual we will
260 use the following abbreviations:
263 means hold the Control key while typing the character <chr>.
264 Thus C\-f would be: hold the Control key and type f.
267 means hold the Meta or Alt key down while typing <chr>.
268 If there is no Meta or Alt key, type
270 release it, then type the character <chr>.
273 means hold the Shift key down while typing <chr>.
275 All input lines in the Midnight Commander use an approximation to
276 the GNU Emacs editor's key bindings (default).
278 You may redefine key bindings. See
280 .I redefine hotkey bindings
283 for more info. All other key bindings (described in this manual) relative
287 There are many sections which tell about the keys. The following are
294 section documents the keyboard shortcuts for the commands appearing in
295 the File menu. This section includes the function keys. Most of these
296 commands perform some action, usually on the selected file or the
303 section documents the keys which select a file or tag files as a
304 target for a later action (the action is usually one from the file
310 .\"Shell Command Line"
311 section list the keys which are used for entering and editing command
312 lines. Most of these copy file names and such from the directory
313 panels to the command line (to avoid excessive typing) or access the
314 command line history.
319 are used for editing input lines. This means both the command line and
320 the input lines in the query dialogs.
322 .\"NODE " Keys_redefine"
323 .SH " Redefine hotkey bindings"
324 Hotkey bindings may be read from external file (keymap\-file).
325 A keymap\-file is searched on the following algorithm (to the first one found):
328 1) command line option
331 .B \-\-keymap=\<keymap\>
333 2) Environment variable
339 .B [Midnight\-Commander]
343 .B ~/.local/share/mc/mc.keymap
346 .B @sysconfdir@/mc/mc.keymap
349 .B @prefix@/share/mc/mc.keymap
351 Command line option, environment variable and parameter in config file may
352 contain the absolute path to the keymap\-file (with the extension \.keymap
353 or without it). Search of keymap\-file will occur in (to the first one found):
363 .B @prefix@/share/mc/
365 .\"NODE " Miscellaneous Keys"
366 .SH " Miscellaneous Keys"
367 Here are some keys which don't fall into any of the other categories:
370 if there is some text in the command line (the one at the bottom of
371 the panels), then that command is executed. If there is no text in the
372 command line then if the selection bar is over a directory the
373 Midnight Commander does a
375 to the selected directory and reloads the information on the panel;
376 if the selection is an executable file then it is executed. Finally,
377 if the extension of the selected file name matches one of the
381 .\"Extension File Edit"
382 then the corresponding command is executed.
385 repaint all the information in the Midnight Commander.
392 command on a file or on the tagged files.
399 command on the current file or on the tagged files.
402 run the hard link command.
405 run the absolute symbolic link command.
408 run the relative symbolic link command. See the
412 section for more information about symbolic links.
415 set the other panel display mode to information.
418 set the other panel display mode to quick view.
424 .\"External panelize"
430 add directory to hotlist
435 executes the Filtered view command, described in the
438 .\"Internal File Viewer"
455 when the program is being run in the Linux or FreeBSD console or under
456 an xterm, it will show you the output of the previous command. When ran
457 on the Linux console, the Midnight Commander uses an external program
458 (cons.saver) to handle saving and restoring of information on the
461 When the subshell support is compiled in, you can type C\-o at any time
462 and you will be taken back to the Midnight Commander main screen, to
463 return to your application just type C\-o. If you have an application
464 suspended by using this trick, you won't be able to execute other
465 programs from the Midnight Commander until you terminate the suspended
467 .\"NODE " Directory Panels"
468 .SH " Directory Panels"
469 This section lists the keys which operate on the directory panels. If
470 you want to know how to change the appearance of the panels take a
471 look at the section on
473 Left and Right Menus\&.
474 .\"Left and Right Menus"
477 change the current panel. The old other panel becomes the new current
478 panel and the old current panel becomes the new other panel. The
479 selection bar moves from the old current panel to the new current
483 to tag files you may use the Insert key (the kich1 terminfo sequence).
484 To untag files, just retag a tagged file.
487 to change charset of panel you may use M\-e (Alt\-e).
488 Recoding is made from selected codepage into system codepage. To
489 cancel the recoding you may select "directory up" (..) in active panel.
490 To cancel the charsets in all directories, select "No translation " in
491 the dialog of encodings.
493 .B Alt\-g, Alt\-r, Alt\-j
494 used to select the top file in a panel, the middle file and the bottom one,
498 toggle the current display listing to show the next display listing
500 With this it is possible to quickly switch to brief listing, long
501 listing, user defined listing mode, and back to the default.
503 .B C\-\\\\ (control\-backslash)
508 and change to the selected directory.
511 this is used to select (tag) a group of files. The Midnight Commander
512 will prompt for a selection options. When
514 checkbox is on, only files will be selected. If
516 is off, as files as directories will be selected.
519 checkbox is on, the regular expression is much like the filename globbing
520 in the shell (* standing for zero or more characters and ? standing
521 for one character). If
523 is off, then the tagging of files is done with normal regular
524 expressions (see ed (1)). When
526 checkbox is on, the selection will be case sensitive characters.
529 is off, the case will be ignored.
532 use the "\\" key to unselect a group of files. This is the opposite of
536 move the selection bar to the previous entry in the panel.
539 move the selection bar to the next entry in the panel.
542 move the selection bar to the first entry in the panel.
545 move the selection bar to the last entry in the panel.
548 move the selection bar one page down.
550 .B prev\-page, Alt\-v
551 move the selection bar one page up.
554 If the currently selected file is a directory, load that directory on
555 the other panel and moves the selection to the next file. If the
556 currently selected file is not a directory, load the parent directory
557 on the other panel and moves the selection to the next file.
560 make the current directory of the current panel also the current
561 directory of the other panel. Put the other panel to the listing mode
562 if needed. If the current panel is panelized, the other panel doesn't
565 .B C\-PageUp, C\-PageDown
566 only when supported by the terminal: change to ".." and to the currently
567 selected directory respectively.
570 moves to the previous directory in the history, equivalent to clicking
576 moves to the next directory in the history, equivalent to clicking the
580 .B Alt\-Shift\-h, Alt\-H
581 displays the directory history, equivalent to depressing the 'v' with
583 .\"NODE " Quick search"
585 The Quick search mode allows to perform fast file search in file panel.
590 to start a filename search in the directory listing.
592 When the search is active, the user input will be added to the search string
593 instead of the command line. If the
595 option is enabled the search string is shown on the mini\-status
596 line. When typing, the selection bar will move to the next file
597 starting with the typed letters. The
601 keys can be used to correct typing mistakes. If C\-s is pressed
602 again, the next match is searched for.
604 If quick search is started with double pressing of C\-s, the previous quick
605 search pattern will be used for current search.
607 Besides the filename characters, you can also use wildcard
608 characters '*' and '?'.
609 .\"NODE " Shell Command Line"
610 .SH " Shell Command Line"
611 This section lists keys which are useful to avoid excessive typing when
612 entering shell commands.
615 copy the currently selected file name to the command line.
618 same a Alt\-Enter. May not work on remote systems and some terminals.
621 copy the full path name of the currently selected file to the command
622 line. May not work on remote systems and some terminals.
625 does the filename, command, variable, username and hostname
632 copy the tagged files (or if there are no tagged files, the selected
633 file) of the current panel (C\-x t) or of the other panel (C\-x C\-t) to
637 the first key sequence copies the current path name to the command
638 line, and the second one copies the unselected panel's path name to
642 the quote command can be used to insert characters that are otherwise
643 interpreted by the Midnight Commander (like the '+' symbol)
646 use these keys to browse through the command history. Alt\-p takes you
647 to the last entry, Alt\-n takes you to the next one.
650 displays the history for the current input line.
651 .\"NODE " General Movement Keys"
652 .SH " General Movement Keys"
653 The help viewer, the file viewer and the directory tree use common
654 code to handle moving. Therefore they accept exactly the same
655 keys. Each of them also accepts some keys of its own.
657 Other parts of the Midnight Commander use some of the same movement
658 keys, so this section may be of use for those parts too.
661 moves one line backward.
664 moves one line forward.
666 .B Prev Page, Page Up, Alt\-v
669 .B Next Page, Page Down, C\-v
673 moves to the beginning.
678 The help viewer and the file viewer accept the following keys in
679 addition the to ones mentioned above:
681 .B b, C\-b, C\-h, Backspace, Delete
688 moves one half of a page up or down.
691 moves to the beginning or to the end.
692 .\"NODE " Input Line Keys"
693 .SH " Input Line Keys"
694 The input lines (they are used for the
697 .\"Shell Command Line"
698 and for the query dialogs in the program) accept these keys:
701 puts the cursor at the beginning of line.
704 puts the cursor at the end of the line.
707 move the cursor one position left.
710 move the cursor one position right.
713 moves one word forward.
716 moves one word backward.
719 delete the previous character.
722 delete the character in the point (over the cursor).
725 sets the mark for cutting.
728 copies the text between the cursor and the mark to a kill buffer and
729 removes the text from the input line.
732 copies the text between the cursor and the mark to a kill buffer.
735 yanks back the contents of the kill buffer.
738 kills the text from the cursor to the end of the line.
741 Use these keys to browse through the command history. Alt\-p takes you
742 to the last entry, Alt\-n takes you to the next one.
744 .B Alt\-C\-h, Alt\-Backspace
745 delete one word backward.
748 does the filename, command, variable, username and hostname
756 The menu bar pops up when you press F9 or click the mouse on the top
757 row of the screen. The menu bar has five menus: "Left", "File",
758 "Command", "Options" and "Right".
763 .\"Left and Right Menus"
764 allow you to modify the appearance of the left and right directory
771 lists the actions you can perform on the currently selected file or
778 lists the actions which are more general and bear no relation to the
779 currently selected file or the tagged files.
785 lists the actions which allow you to customize the Midnight Commander.
786 .\"NODE " Left and Right Menus"
787 .SH " Left and Right (Above and Below) Menus"
788 The outlook of the directory panels can be changed from the
792 menus (they are named
796 when the horizontal panel split is chosen from the
801 .\"NODE " Listing Mode..."
802 .SH " Listing Mode..."
803 The listing mode view is used to display a listing of files, there are
804 four different listing modes available:
810 The full directory view shows the file name, the size of the file and
811 the modification time.
813 The brief view shows only the file name and it has two columns
814 (therefore showing twice as many files as other views). The long view
815 is similar to the output of
817 command. The long view takes the whole screen width.
819 If you choose the "User" display format, then you have to specify
822 The user display format must start with a panel size specifier. This
823 may be "half" or "full", and they specify a half screen panel and a
824 full screen panel respectively.
826 After the panel size, you may specify the two columns mode on the
827 panel, this is done by adding the number "2" to the user format
830 After this you add the name of the fields with an optional size
831 specifier. This are the available fields you may display:
834 displays the file name.
837 displays the file size.
840 is an alternative form of the
842 format. It displays the size of the files and for directories it just
843 shows SUB\-DIR or UP\-\-DIR.
846 displays a one character wide type field. This character is similar to
847 what is displayed by ls with the \-F flag \-
849 for executable files,
857 for character devices,
863 for symbolic links to directories and
865 for stale symlinks (links that point nowhere).
868 an asterisk if the file is tagged, a space if it's not.
871 file's last modification time.
874 file's last access time.
877 file's status change time.
880 a string representing the current permission bits of the file.
883 an octal value with the current permission bits of the file.
886 the number of links to the file.
895 the owner of the file.
898 the group of the file.
901 the inode of the file.
903 Also you can use following keywords to define the panel layout:
906 a space in the display format.
909 add a vertical line to the display format.
911 To force one field to a fixed size (a size specifier), you just add
913 followed by the number of characters you want the field to have. If the
914 number is followed by the symbol
916 then the size specifies the minimal field size \- if the program finds
917 out that there is more space on the screen, it will then expand that
922 display corresponds to this format:
924 half type name | size | mtime
928 display corresponds to this format:
930 full perm space nlink space owner space group space size space mtime
933 This is a nice user display format:
935 half name | size:7 | type mode:3
937 Panels may also be set to the following modes:
940 The info view display information related to the currently
941 selected file and if possible information about the current file
945 The tree view is quite similar to the
949 feature. See the section about it for more information.
952 In this mode, the panel will switch to a reduced
955 .\"Internal File Viewer"
956 that displays the contents of the currently selected file, if you
957 select the panel (with the tab key or the mouse), you will have access
958 to the usual viewer commands.
959 .\"NODE " Sort Order..."
961 The eight sort orders are by name, by extension, by modification time,
962 by access time, and by inode information modification time, by size,
963 by inode and unsorted. In the Sort order dialog box you can choose
964 the sort order and you may also specify if you want to sort in reverse
965 order by checking the reverse box.
967 By default directories are sorted before files but this can be changed
973 .BR "Mix all files" ).
976 The filter command allows you to specify a shell pattern (for example
978 which the files must match to be shown. Regardless
979 of the filter pattern, the directories and the links to directories
980 are always shown in the directory panel.
983 The reread command reload the list of files in the directory. It is
984 useful if other processes have created or removed files. If you
985 have panelized file names in a panel this will reload the directory
986 contents and remove the panelized information (See the section
989 .\"External panelize"
990 for more information).
993 The Midnight Commander uses the F1 \- F10 keys as keyboard shortcuts
994 for commands appearing in the file menu. The escape sequences for the
995 function keys are terminfo capabilities kf1 trough kf10. On terminals
996 without function key support, you can achieve the same functionality by
997 pressing the ESC key and then a number in the range 1 through 9 and 0
998 (corresponding to F1 to F9 and F10 respectively).
1000 The File menu has the following commands (keyboard shortcuts in parentheses):
1004 Invokes the built\-in hypertext help viewer. Inside the
1008 you can use the Tab key to select the next link and the Enter key to
1009 follow that link. The keys Space and Backspace are used to move
1010 forward and backward in a help page. Press F1 again to get the full
1011 list of accepted keys.
1019 The user menu provides an easy way to provide users with a menu and
1020 add extra features to the Midnight Commander.
1024 View the currently selected file. By default this invokes the
1026 Internal File Viewer
1027 .\"Internal File Viewer"
1028 but if the option "Use internal view" is off, it invokes an external
1029 file viewer specified by the
1031 environment variable. If
1035 environment variable is tried. If
1037 is also undefined, the "view" command is invoked. If you use F13
1038 instead, the viewer will be invoked without doing any formatting or
1039 preprocessing to the file.
1041 .B Filtered View (Alt\-!)
1043 This command prompts for a command
1044 and its arguments (the argument defaults to the currently selected
1045 file name), the output from such command is shown in the internal file
1050 Press F4 to edit the highlighted file. Press F14 (usually F14)
1051 to start the editor with a new, empty file.
1052 Currently they invoke the
1054 editor, or the editor specified in the
1056 environment variable, or the
1058 Internal File Editor
1059 .\"Internal File Editor"
1060 if the use_internal_edit option is on.
1064 Press F5 to pop up an input dialog to copy the currently selected file (or
1065 the tagged files, if there is at least one file tagged) to the
1066 directory/filename you specify in the input dialog. The destination
1067 defaults to the directory in the non\-selected panel. During this
1068 process, you can press C\-c or ESC to abort the operation. For details
1069 about source mask (which will be usually either * or ^\\(.*\\)$ depending
1070 on setting of Use shell patterns) and possible wildcards in the destination
1074 .\"Mask Copy/Rename"
1076 F15 (usually F15) is similar, but defaults to the directory in the
1077 selected panel. It always operates on the selected file, regardless of
1080 On some systems, it is possible to do the copy in the background by
1081 clicking on the background button (or pressing Alt\-b in the dialog
1086 is used to control the background process.
1090 Create a hard link to the current file.
1092 .B Absolute symlink (C\-x s)
1094 Create a absolute symbolic link to the current file.
1096 .B Relative symLink (C\-x v)
1098 Create a relative symbolic link to the current file.
1100 To those of you who don't know what links are: creating a link to a file
1101 is a bit like copying the file, but both the source filename and the destination
1102 filename represent the same file image. For example, if you edit one of these
1103 files, all changes you make will appear in both files. Some people call
1104 links aliases or shortcuts.
1106 A hard link appears as a real file. After making it, there is no way of
1107 telling which one is the original and which is the link. If you delete
1108 either one of them the other one is still intact. It is very difficult
1109 to notice that the files represent the same image. Use hard links when
1110 you don't even want to know.
1112 A symbolic link is a reference to the name of the original file. If
1113 the original file is deleted the symbolic link is useless. It is quite
1114 easy to notice that the files represent the same image. The Midnight
1115 Commander shows an "@"\-sign in front of the file name if it is a
1116 symbolic link to somewhere (except to directory, where it shows a tilde (~)).
1117 The original file which the link points to is shown on mini\-status line if the
1118 .I "Show mini\-status"
1119 option is enabled. Use symbolic links when you want to avoid the
1120 confusion that can be caused by hard links.
1122 When you press "C\-x s" Midnight Commander will automatically fill in the
1123 complete path+filename of the original file and suggest a name for the link.
1124 You can change either one.
1126 Sometimes you may want to change the absolute path of the original into
1127 a relative path. An absolute path starts from the root directory:
1129 .I /home/frodo/mc/mc -> /home/frodo/new/mc
1131 A relative link describes the original file's location starting from the
1132 location of the link itself:
1134 .I /home/frodo/mc/mc -> ../new/mc
1136 You can force Midnight Commander to suggest a relative path by pressing
1137 "C\-x v" instead of "C\-x s".
1139 .B Rename/Move (F6, F16)
1141 Press F6 to pop up an input dialog to copy the currently selected file (or
1142 the tagged files, if there is at least one file tagged) to the
1143 directory/filename you specify in the input dialog. The destination
1144 defaults to the directory in the non\-selected panel. For more details
1145 look at Copy (F5) operation above, most of the things are quite similar.
1147 F16 (usually F16) is similar, but defaults to the directory in the
1148 selected panel. It always operates on the selected file, regardless of
1151 On some systems, it is possible to do the copy in the background by
1152 clicking on the background button (or pressing Alt\-b in the dialog
1157 is used to control the background process.
1161 Pop up an input dialog and creates the directory specified.
1165 Delete the currently selected file or the tagged files in the
1166 currently selected panel. During the process, you can press C\-c or
1167 ESC to abort the operation.
1169 .B Quick cd (Alt\-c)
1174 command if you have full command line and want to cd somewhere.
1178 This is used to select (tag) a group of files. The Midnight Commander
1179 will prompt for a selection options. When
1181 checkbox is on, only files will be selected. If
1183 is off, as files as directories will be selected.
1186 checkbox is on, the regular expression is much like the filename globbing
1187 in the shell (* standing for zero or more characters and ? standing
1188 for one character). If
1190 is off, then the tagging of files is done with normal regular
1191 expressions (see ed (1)). When
1193 checkbox is on, the selection will be case sensitive characters.
1196 is off, the case will be ignored.
1198 .B Unselect group (\\\\)
1200 Used to unselect a group of files. This is the opposite of the
1204 .B Quit (F10, Shift\-F10)
1206 Terminate the Midnight Commander. Shift\-F10 is used when you want to
1207 quit and you are using the shell wrapper. Shift\-F10 will not take you
1208 to the last directory you visited with the Midnight Commander, instead
1209 it will stay at the directory where you started the Midnight Commander.
1212 This command is useful if you have a full command line and want to
1215 .\"The cd internal command"
1216 somewhere without having to yank and paste the command line. This command
1217 pops up a small dialog, where you enter everything you would enter after
1219 on the command line and then you press enter. This features all the things
1220 that are already in the
1222 internal cd command\&.
1223 .\"The cd internal command"
1224 .\"NODE " Command Menu"
1230 command shows a tree figure of the directories.
1236 command allows you to search for a specific file.
1238 The "Swap panels" command swaps the contents of the two directory panels.
1240 The "Switch panels on/off" command shows the output of the last shell command.
1241 This works only on xterm and on Linux and FreeBSD console.
1243 The "Compare directories" command compares the directory
1244 panels with each other. You can then use the Copy (F5) command to make
1245 the panels identical. There are three compare methods. The quick method
1246 compares only file size and file date. The thorough method makes a
1247 full byte\-by\-byte compare. The thorough method is not available if the
1248 machine does not support the mmap(2) system call. The size\-only
1249 compare method just compares the file sizes and does not check the
1250 contents or the date times, it just checks the file size.
1255 .\"External panelize"
1256 allows you to execute an external program, and make the output of that
1257 program the contents of the current panel.
1259 The "Command history" command shows a list of typed commands. The
1260 selected command is copied to the command line. The command history
1261 can also be accessed by typing Alt\-p or Alt\-n.
1267 command makes changing of the current directory to often used directories
1274 command shows a dialog window with the list of currently running
1275 internal editors, viewers and other MC modules that support this mode.
1279 "Edit extension file"
1280 .\"Extension File Edit"
1281 command allows you to specify programs to executed when you try to
1282 execute, view, edit and do a bunch of other thing on files
1283 with certain extensions (filename endings).
1289 command may be used for editing the user menu (which appears by
1291 .\"NODE " Directory Tree"
1292 .SH " Directory Tree"
1293 The Directory Tree command shows a tree figure of the directories. You
1294 can select a directory from the figure and the Midnight Commander will
1295 change to that directory.
1297 There are two ways to invoke the tree. The real directory tree command
1298 is available from Commands menu. The other way is to select tree view
1299 from the Left or Right menu.
1301 To get rid of long delays the Midnight Commander creates the tree
1302 figure by scanning only a small subset of all the directories. If the
1303 directory which you want to see is missing, move to its parent
1304 directory and press C\-r (or F2).
1306 You can use the following keys:
1309 General movement keys
1310 .\"General Movement Keys"
1314 In the directory tree, exits the directory tree and changes to this
1315 directory in the current panel. In the tree view, changes to this
1316 directory in the other panel and stays in tree view mode in the
1319 .B C\-r, F2 (Rescan).
1320 Rescan this directory. Use this when the tree figure is out of date:
1321 it is missing subdirectories or shows some subdirectories which don't
1325 Delete this directory from the tree figure. Use this to remove clutter
1326 from the figure. If you want the directory back to the tree figure
1327 press F2 in its parent directory.
1329 .B F4 (Static/Dynamic).
1330 Toggle between the dynamic navigation mode (default) and the static
1333 In the static navigation mode you can use the Up and Down keys to
1334 select a directory. All known directories are shown.
1336 In the dynamic navigation mode you can use the Up and Down keys to
1337 select a sibling directory, the Left key to move to the parent
1338 directory, and the Right key to move to a child directory. Only the
1339 parent, sibling and children directories are shown, others are left
1340 out. The tree figure changes dynamically as you traverse.
1349 Make a new directory below this directory.
1352 Delete this directory from the file system.
1355 Search the next directory matching the search string. If there is
1356 no such directory these keys will move one line down.
1359 Delete the last character of the search string.
1361 .B Any other character.
1362 Add the character to the search string and move to the next directory
1363 which starts with these characters. In the tree view you must first
1364 activate the search mode by pressing C\-s. The search string is shown
1365 in the mini status line.
1367 The following actions are available only in the directory tree. They
1368 aren't supported in the tree view.
1371 Invoke the help viewer and show this section.
1374 Exit the directory tree. Do not change the directory.
1376 The mouse is supported. A double\-click behaves like Enter. See
1381 .\"NODE " Find File"
1383 The Find File feature first asks for the start directory for the
1384 search and the filename to be searched for. By pressing the Tree
1385 button you can select the start directory from the
1391 Option \"Whole words\" allows select only those files containing matches that
1392 form whole words. Like grep \-w.
1394 You can start the search by pressing the OK button.
1395 During the search you can stop from the Stop button and continue from
1398 You can browse the filelist with the up and down arrow keys. The Chdir
1399 button will change to the directory of the currently selected
1400 file. The Again button will ask for the parameters for a new
1401 search. The Quit button quits the search operation. The Panelize
1402 button will place the found files to the current directory panel so
1403 that you can do additional operations on them (view, copy, move,
1404 delete and so on). After panelizing you can press C\-r to return to the
1405 normal file listing.
1407 The 'Enable ignore directories' checkbox and input field below it
1408 allow to set up the list of directories that should be skip during the search
1409 files (for example, you may want to avoid searches on a CD\-ROM or on a NFS
1410 directory that is mounted across a slow link). List components must be separated
1411 with a colon, here is an example:
1414 /cdrom:/nfs/wuarchive:/afs
1417 Relative paths are supported also. The following example shows how to skip special
1418 directories of version control systems:
1420 /cdrom:/nfs/wuarchive:/afs:.svn:.git:CVS
1423 Attention: input field can contain a dot (.), this means the current absolute path.
1425 You may consider using the
1428 .\"External panelize"
1429 command for some operations. Find file command is for simple queries
1430 only, while using External panelize you can do as mysterious searches
1432 .\"NODE " External panelize"
1433 .SH " External panelize"
1434 The External panelize allows you to execute an external program, and
1435 make the output of that program the contents of the current panel.
1437 For example, if you want to manipulate in one of the panels all the
1438 symbolic links in the current directory, you can use external
1439 panelization to run the following command:
1442 find . \-type l \-print
1445 Upon command completion, the directory contents of the panel will no
1446 longer be the directory listing of the current directory, but all the
1447 files that are symbolic links.
1449 If you want to panelize all of the files that have been downloaded
1450 from your FTP server, you can use this awk command to extract the file
1451 name from the transfer log files:
1454 awk '$9 ~! /incoming/ { print $9 }' < /var/log/xferlog
1457 You may want to save often used panelize commands under a descriptive name,
1458 so that you can recall them quickly. You do this by typing the command on
1459 the input line and pressing Add new button. Then you enter a name under
1460 which you want the command to be saved. Next time, you just choose that
1461 command from the list and do not have to type it again.
1464 The Directory hotlist command shows the labels of the directories
1465 in the directory hotlist. The Midnight Commander will change to the
1466 directory corresponding to the selected label. From the hotlist dialog,
1467 you can remove already created label/directory pairs and add new ones.
1468 To add new directories quickly, you can use the Add to hotlist command
1469 (C\-x h), which adds the current directory into the directory hotlist,
1470 asking just for the label for the directory.
1472 This makes cd to often used directories faster. You may consider using the
1473 CDPATH variable as described in
1476 .\"The cd internal command"
1478 .\"NODE " Extension File Edit"
1479 .SH " Extension File Edit"
1480 This will invoke your editor on the file
1481 .IR ~/.local/share/mc/mc.ext .
1482 The format of this file following:
1484 All lines starting with # or empty lines are thrown away.
1486 Lines starting in the first column should have following format:
1489 i.e. everything after the slash until new line is
1498 is an extension (no wildcards). File matches it its name ends
1509 is a regular expression. File matches if its name matches the regular
1515 is a regular expression. File matches if it is a directory and its name
1516 matches the regular expression.
1521 is a regular expression. File matches if the output of
1523 without the initial "filename:" part matches regular expression
1527 \- matches any file.
1532 \- denotes a common section.
1534 is the name of the section.
1536 Other lines should start with a space or tab and should be of the format:
1538 (with no spaces around =), where
1542 (invoked on Enter or double click),
1548 (to add rules from the common section).
1550 is any one\-line shell command, with the simple
1552 macro substitution\&.
1553 .\"Macro Substitution"
1555 Rules are matched from top to bottom, thus the order is important. If
1556 the appropriate action is missing, search continues as if this rule
1557 didn't match (i.e. if a file matches the first and second entry and View
1558 action is missing in the first one, then on pressing F3 the View action
1559 from the second entry will be used).
1561 should match all the actions.
1562 .\"NODE " Background jobs"
1563 .SH " Background Jobs"
1564 This lets you control the state of any background Midnight Commander
1565 process (only copy and move files operations can be done in the
1566 background). You can stop, restart and kill a background job from
1568 .\"NODE " Menu File Edit"
1569 .SH " Menu File Edit"
1570 The user menu is a menu of useful actions that can be customized by
1571 the user. When you access the user menu, the
1572 file .mc.menu from the current directory is used if it exists,
1573 but only if it is owned by user or root and is not world\-writable.
1574 If no such file found, ~/.local/share/mc/menu is tried in the same way,
1575 and otherwise mc uses the default system\-wide menu
1576 @prefix@/share/mc/mc.menu.
1578 The format of the menu file is very simple. Lines that start with
1579 anything but space or tab are considered entries for the menu (in
1580 order to be able to use it like a hot key, the first character should
1581 be a letter). All the lines that start with a space or a tab are the
1582 commands that will be executed when the entry is selected.
1584 When an option is selected all the command lines of the option are
1585 copied to a temporary file in the temporary directory (usually
1586 /usr/tmp) and then that file is executed. This allows the user to put
1587 normal shell constructs in the menus. Also simple macro substitution
1588 takes place before executing the menu code. For more information, see
1590 macro substitution\&.
1591 .\"Macro Substitution"
1593 Here is a sample mc.menu file:
1596 A Dump the currently selected file
1599 B Edit a bug report and send it to root
1600 I=`mktemp ${MC_TMPDIR:\-/tmp}/mail.XXXXXX` || exit 1
1602 mail \-s "Midnight Commander bug" root < $I
1611 H Call the info hypertext browser
1614 J Copy current directory to other panel recursively
1615 tar cf \- . | (cd %D && tar xvpf \-)
1617 K Make a release of the current subdirectory
1618 echo \-n "Name of distribution file: "
1620 ln \-s %d `dirname %d`/$tar
1622 tar cvhf ${tar}.tar $tar
1624 = f *.tar.gz | f *.tgz & t n
1625 X Extract the contents of a compressed tar file
1629 .B Default Conditions
1631 Each menu entry may be preceded by a condition. The condition must
1632 start from the first column with a '=' character. If the condition is
1633 true, the menu entry will be the default entry.
1636 Condition syntax: = <sub\-cond>
1637 or: = <sub\-cond> | <sub\-cond> ...
1638 or: = <sub\-cond> & <sub\-cond> ...
1640 Sub\-condition is one of following:
1642 y <pattern> syntax of current file matching pattern?
1643 (for edit menu only)
1644 f <pattern> current file matching pattern?
1645 F <pattern> other file matching pattern?
1646 d <pattern> current directory matching pattern?
1647 D <pattern> other directory matching pattern?
1648 t <type> current file of type?
1649 T <type> other file of type?
1650 x <filename> is it executable filename?
1651 ! <sub\-cond> negate the result of sub\-condition
1654 Pattern is a normal shell pattern or a regular expression, according
1655 to the shell patterns option. You can override the global value of
1656 the shell patterns option by writing "shell_patterns=x" on the first
1657 line of the menu file (where "x" is either 0 or 1).
1659 Type is one or more of the following characters:
1674 For example 'rlf' means either regular file, link or fifo. The 't'
1675 type is a little special because it acts on the panel instead of the
1676 file. The condition '=t t' is true if there are tagged files in the
1677 current panel and false if not.
1679 If the condition starts with '=?' instead of '=' a debug trace will be
1680 shown whenever the value of the condition is calculated.
1682 The conditions are calculated from left to right. This means
1684 = f *.tar.gz | f *.tgz & t n
1688 ( (f *.tar.gz) | (f *.tgz) ) & (t n)
1691 Here is a sample of the use of conditions:
1694 = f *.tar.gz | f *.tgz & t n
1695 L List the contents of a compressed tar\-archive
1696 gzip \-cd %f | tar xvf \-
1699 .B Addition Conditions
1701 If the condition begins with '+' (or '+?') instead of '=' (or '=?') it
1702 is an addition condition. If the condition is true the menu entry will
1703 be included in the menu. If the condition is false the menu entry will
1704 not be included in the menu.
1706 You can combine default and addition conditions by starting condition
1707 with '+=' or '=+' (or '+=?' or '=+?' if you want debug trace). If you
1708 want to use two different conditions, one for adding and another for
1709 defaulting, you can precede a menu entry with two condition lines, one
1710 starting with '+' and another starting with '='.
1712 Comments are started with '#'. The additional comment lines must start
1713 with '#', space or tab.
1714 .\"NODE " Options Menu"
1716 The Midnight Commander has some options that may be toggled on and
1717 off in several dialogs which are accessible from this menu. Options
1718 are enabled if they have an asterisk or "x" in front of them.
1724 command pops up a dialog from which you can change most of settings of
1725 the Midnight Commander.
1731 command pops up a dialog from which you specify a bunch of options how mc
1732 looks like on the screen.
1738 command pops up a dialog from which you specify options of file manager panels.
1744 command pops up a dialog from which you specify which actions you want to
1751 command pops up a dialog from which you may select which characters is your
1752 terminal able to display.
1758 command pops up a dialog from which you test some keys which are not working
1759 on some terminals and you may fix them.
1765 command pops up a dialog from which you specify some VFS related options.
1771 command saves the current settings of the Left, Right and Options
1772 menus. A small number of other settings is saved, too.
1773 .\"NODE " Configuration"
1774 .SH " Configuration"
1775 The options in this dialog are divided into several groups: "File
1776 operation options", "Esc key mode", "Pause after run" and "Other options".
1778 .B File operation options
1780 .I Verbose operation.
1781 This toggles whether the file Copy, Rename and Delete operations are
1782 verbose (i.e., display a dialog box for each operation). If you have a
1783 slow terminal, you may wish to disable the verbose operation. It is
1784 automatically turned off if the speed of your terminal is less than
1788 If this option is enabled, the Midnight Commander computes total byte
1789 sizes and total number of files prior to any Copy, Rename and Delete
1790 operations. This will provide you with a more accurate progress bar
1791 at the expense of some speed. This option has no effect, if
1792 .I Verbose operation
1795 .I Classic progressbar.
1796 If this option is enabled, the progressbar of Copy/Move/Delete operations
1797 is always grown form left to right. If disabled, the growing direction
1798 of progressbar follows to direction of Copy/Move/Delete operation:
1799 from left panel to right one and vice versa. Enabled by default.
1802 When you press F7 to create a new directory, the input line in popup dialog
1803 will be filled by name of current file or directory in active panel.
1804 Disabled by default.
1808 By default the Midnight Commander treats the ESC key as a key prefix.
1809 Therefore, you should press Esc code twice to exit a dialog. But there is
1810 a possibility to use a single press of ESC key for that action.
1813 By default this option is disabled. If you'll enable it, the ESC key
1814 will act as a prefix key for set up time interval (see
1816 option below), and if no extra keys have arrived, then the ESC key
1817 is interpreted as a cancel key (ESC ESC).
1820 This options is used to setup the time interval (in microseconds)
1821 for single press of ESC key. By default, this inrerval is one second
1822 (1000000 microseconds). Also the timeout can be set via KEYBOARD_KEY_TIMEOUT_US
1823 environment variable (also in microseconds), which has higher priority
1824 than Timeout option value.
1828 After executing your commands, the Midnight Commander can pause, so
1829 that you can examine the output of the command. There are three
1830 possible settings for this variable:
1833 Means that you do not want to see the output of your command. If you
1834 are using the Linux or FreeBSD console or an xterm, you will be able to
1835 see the output of the command by typing C\-o.
1837 .IR On dumb terminals .
1838 You will get the pause message on terminals that are not capable of
1839 showing the output of the last command executed (any terminal that is
1840 not an xterm or the Linux console).
1843 The program will pause after executing all of your commands.
1847 .I Use internal editor.
1848 If this option is enabled, the built\-in file editor is used to edit
1849 files. If the option is disabled, the editor specified in the
1851 environment variable is used.
1852 If no editor is specified,
1854 is used. See the section on the
1856 internal file editor\&.
1857 .\"Internal File Editor"
1859 .I Use internal viewer.
1860 If this option is enabled, the built\-in file viewer is used to view
1861 files. If the option is disabled, the pager specified in the
1863 environment variable is used.
1864 If no pager is specified, the
1866 command is used. See the section on the
1868 internal file viewer\&.
1869 .\"Internal File Viewer"
1872 If this option is enabled, the user menu will be invoked at startup.
1873 Useful for building menus for non\-unixers.
1876 When this option is enabled, the pull down menus will be activated as
1877 soon as you press the F9 key. Otherwise, you will only get the menu title,
1878 and you will have to activate the menu either with the arrow keys or with
1879 the hotkeys. It is recommended if you are using hotkeys.
1882 By default the Select, Unselect and Filter commands will use shell\-like
1883 regular expressions. The following conversions are performed to achieve
1884 this: the '*' is replaced by '.*' (zero or more characters); the '?'
1885 is replaced by '.' (exactly one character) and '.' by the literal
1886 dot. If the option is disabled, then the regular expressions are the
1887 ones described in ed(1).
1889 .I Complete: show all.
1890 By default the Midnight Commander pops up all possible
1894 if the completion is ambiguous only when you press
1896 for the second time. For the first time, it just completes as much as
1897 possible and beeps in the case of ambiguity. Enable this option if you
1898 want to see all possible completions even after pressing
1903 If this option is enabled, the
1904 Midnight Commander shows a rotating dash in the upper right corner
1905 as a work in progress indicator.
1907 .I Cd follows links.
1908 This option, if set, causes the Midnight Commander to follow the
1909 logical chain of directories when changing current directory
1910 either in the panels, or using the cd command. This is the default
1911 behavior of bash. When unset, the Midnight Commander follows the
1912 real directory structure, so cd .. if you've entered that directory
1913 through a link will move you to the current directory's real parent
1914 and not to the directory where the link was present.
1917 If this option is enabled, deleting files and directory hotlist entries
1918 unintentionally becomes more difficult. The default selection in the
1919 confirmation dialogs for deletion changes from "Yes" to "No".
1920 This option is disabled by default.
1923 If this option is enabled, when you exit the Midnight Commander the
1924 configurable options of the Midnight Commander are saved in the
1925 ~/.config/mc/ini file.
1928 The layout dialog gives you a possibility to change the general layout
1929 of screen. The options in this dialog are divided into several groups:
1930 "Panel split", "Console output" and "Other options".
1934 The rest of the screen area is used for the two directory panels. You
1935 can specify whether the area is split to the panels in
1939 direction. Panel layout can be changed using Alt\-, (Alt\-comma) shortcut.
1942 By default, panels have equal sizes. Using this option you can specify
1947 On the Linux or FreeBSD console you can specify how many lines are shown
1948 in the output window. This option is available if Midnight Commander runs
1949 on native console only.
1953 .I Menu bar visible.
1954 If enabled, main menu of Midnight Commander is always visible on the top row
1955 of screen above panels. Enabled by default.
1958 If enabled, command line is avalable. Enabled by default.
1961 If enabled, 10 lables associated with F1\-F10 keys are located at the bottom
1962 row of screen. Enabled by default.
1965 If enabled, the one\-line hints are visible below panels. Enabled by default.
1967 .I XTerm window title.
1968 When run in a terminal emulator for X11, Midnight Commander sets the
1969 terminal window title to the current working directory and updates it
1970 when necessary. If your terminal emulator is broken and you see some
1971 incorrect output on startup and directory change, turn off this option.
1975 If enabled, free space and total space of current file system is shown
1976 at the bottom frame of panel. Enabled by default.
1977 .\"NODE " Panel options"
1978 .SH " Panel options"
1979 .B Main panel options
1981 .I Show mini\-status.
1982 If enabled, one line of status information about the currently selected item
1983 is shown at the bottom of the panels. Enabled by default.
1985 .I Use SI size units.
1986 If this option is enabled, Midnight Commander will use SI units (powers of 1000)
1987 when displaying any byte sizes. The suffixes (k, m ...) are shown in lowercase.
1988 If disabled (default), Midnight Commander will use binary units (powers of 1024)
1989 and the suffixes are shown in upper case (K, M ...)
1992 If this option is enabled, all files and directories are shown mixed
1993 together. If the option is desabled (default), directories (and links to
1994 directories) are shown at the beginning of the listing, and other files below.
1996 .I Show backup files.
1997 If enabled, the Midnight Commander will show files ending with a tilde.
1998 Otherwise, they won't be shown (like GNU's ls option \-B). Enabled by default.
2000 .I Show hidden files.
2001 If enabled, the Midnight Commander will show all files that start with
2002 a dot (like ls \-a). Disabled by default.
2004 .I Fast directory reload.
2005 If this option is enabled, the Midnight Commander will use a trick to
2006 determine if the directory contents have changed. The trick is to reload
2007 the directory only if the i\-node of the directory has changed; this means
2008 that reloads only happen when files are created or deleted. If what
2009 changes is the i\-node for a file in the directory (file size changes,
2010 mode or owner changes, etc) the display is not updated. In these cases,
2011 if you have the option on, you have to rescan the directory manually
2012 (with C\-r). Disabled by default.
2015 If enabled, the selection bar will move down when you mark a file (with
2016 Insert key). Enabled by default.
2018 .I Reverse files only.
2019 Allow revert selection of files only. Enabled by default.
2020 If enabled, the reverse selection is applied to files only, not to directories.
2021 The selection of directories is untouched. If off, the reverse selection
2022 is applied to files as well to directories: all unselected items become
2023 selected, and vice versa.
2026 If both panels contain file listing, simple swap means that panels exchange
2027 its screen positions: left panel become right one, and vice versa. If this
2028 option is unchecked, file listing panels exchange its content keeping listing
2029 format and sort options. Unchecked by default.
2031 .I Auto save panels setup.
2032 If this option is enabled, when you exit the Midnight Commander the
2033 current settings of panels are saved in the ~/.cache/mc/panels.ini file.
2034 Disabled by default.
2038 .I Lynx\-like motion.
2039 If this option is enabled, you may use the arrows keys to automatically
2040 chdir if the current selection is a subdirectory and the shell command
2041 line is empty. By default, this setting is off.
2044 If set (the default), panel will scroll by half the display when the
2045 cursor reaches the end or the beginning of the panel, otherwise it
2046 will just scroll a file at a time.
2048 .I Mouse page scrolling.
2049 Controls whenever scrolling with the mouse wheel is done by pages or
2050 line by line on the panels.
2054 You can specify whether
2058 should be highlighted with distinctive
2062 If the permission highlighting is enabled, the parts of the
2069 which apply to the user running Midnight Commander are highlighted with
2070 the color defined by the
2072 keyword. If the file type highlighting is enabled, file names are colored
2073 according to rules described in @sysconfdir@/mc/filehighlight.ini file. See
2076 .\"Filenames Highlight"
2081 You can specify how the
2085 mode should works: case insensitively, case sensitively or be matched
2086 to the the panel sort order: case sensitive or not.
2087 .\"NODE " Confirmation"
2089 In this dialog you configure the confirmation options for file deletion,
2090 overwriting files, execution by pressing enter, quitting the program,
2091 directory hotlist entries deletion and history cleanup.
2093 .\"NODE " Display bits"
2095 This is used to configure the range of visible characters on the
2096 screen. This setting may be 7\-bits if your terminal/curses supports
2097 only seven output bits, ISO\-8859\-1 displays all the characters in the
2098 ISO\-8859\-1 map and full 8 bits is for those terminals that can display
2099 full 8 bit characters.
2100 .\"NODE " Learn keys"
2102 This dialog allows you to test and redefine functional keys, cursor
2103 arrows and some other keys to make them work properly on your terminal.
2104 They often don't, since many terminal databases are incomplete or broken.
2106 You can move around with the Tab key and with the vi moving keys ('h'
2107 left, 'j' down, 'k' up and 'l' right). Once you press any cursor movement
2108 key and it is recognized, you can use that key as well.
2110 You can test keys just by pressing each of them. When you press a
2111 key and it is recognized properly, OK should appear next to the name
2112 of that key. Once a key is marked OK it starts working as usually,
2113 e.g. F1 pressed the first time will just check that the F1 key works,
2114 but after that it will show help. The same applies to the arrow keys.
2115 The Tab key should be working always.
2117 If some keys do not work properly then you won't see OK appear after
2118 pressing one of these. Then you may want to redefine it. Do it by pressing
2119 the button with the name of that key (either by the mouse or by Enter
2120 or Space after selecting the button with Tab or arrows). Then a message
2121 box will appear asking you to press that key. Do it and wait until the
2122 message box disappears. If you want to abort, just press Escape once
2125 When you finish with all the keys, you can Save them. The definitions
2126 for the keys you have redefined will be written into the [terminal:TERM]
2127 section of your ~/.config/mc/ini file (where TERM is the name of your current
2128 terminal). The definitions of the keys that were already working properly
2130 .\"NODE " Virtual FS"
2132 This option gives you control over the settings of the
2134 Virtual File System\&.
2135 .\"Virtual File System"
2137 The Midnight Commander keeps in memory the information related to some
2138 of the virtual file systems to speed up the access to the files in the
2139 file system (for example, directory listings fetched from FTP servers).
2141 Also, in order to access the contents of compressed files (for example,
2142 compressed tar files) the Midnight Commander needs to create temporary
2143 uncompressed files on your disk.
2145 Since both the information in memory and the temporary files on disk
2146 take up resources, you may want to tune the parameters of the cached
2147 information to decrease your resource usage or to maximize the speed of
2148 access to frequently used file systems.
2150 Because of the format of the tar archives, the
2152 needs to read the whole file just to load the file entries. Since most
2153 tar files are usually kept compressed (plain tar files are species in
2154 extinction), the tar file system has to uncompress the file on the disk
2155 in a temporary location and then access the uncompressed file as a
2158 Now, since we all love to browse files and tar files all over the disk,
2159 it's common that you will leave a tar file and then re\-enter it later.
2160 Since decompression is slow, the Midnight Commander will cache the
2161 information in memory for a limited time. When the timeout expires, all
2162 the resources associated with the file system are released. The default
2163 timeout is set to one minute.
2169 (ftpfs) allows you to browse directories on remote FTP servers. It has
2172 .I ftp anonymous password
2173 is the password used when you login as "anonymous". Some sites require
2174 a valid e\-mail address. On the other hand, you probably don't want to
2175 give your real e\-mail address to untrusted sites, especially if you are
2176 not using spam filtering.
2178 ftpfs keeps the directory listing it fetches from a FTP server in a cache.
2179 The cache expire time is configurable with the
2180 .I ftpfs directory cache timeout
2181 option. A low value for this option may slow down every operation on
2182 the ftpfs because every operation would require sending a request to the
2185 You can define an FTP proxy host for doing FTP. Note that most modern
2186 firewalls are fully transparent at least for passive FTP (see below), so
2187 FTP proxies are considered obsolete.
2190 .I Always use ftp proxy
2191 is not set, you can use the exclamation sign to enable proxy for certain
2198 If this option is set, the program will do two things: consult the
2199 @prefix@/lib/mc/mc.no_proxy file for lines containing host names that
2200 are local (if the host name starts with a dot, it is assumed to be a
2201 domain) and to assume that any hostnames without dots in their names are
2202 directly accessible. All other hosts will be accessed through the
2203 specified FTP proxy.
2205 You can enable using
2207 file, which keeps login names and passwords for ftp servers. See netrc
2208 (5) for the description of the .netrc format.
2211 enables using FTP passive mode, when the connection for data transfer is
2212 initiated by the client, not by the server. This option is recommended
2213 and enabled by default. If this option is turned off, the data
2214 connection is initiated by the server. This may not work with some
2216 .\"NODE " Save Setup"
2218 At startup the Midnight Commander will try to load initialization
2219 information from the ~/.config/mc/ini file. If this file
2220 doesn't exist, it will load the information from the system\-wide
2221 configuration file, located in @prefix@/share/mc/mc.ini. If the
2222 system\-wide configuration file doesn't exist, MC uses the default settings.
2226 command creates the ~/.config/mc/ini file by saving the
2227 current settings of the
2230 .\"Left and Right Menus"
2239 option, MC will always save the current settings when exiting.
2241 There also exist settings which can't be changed from the menus. To
2242 change these settings you have to edit the setup file with your
2243 favorite editor. See the section on
2246 .\"Special Settings"
2247 for more information.
2249 .\"NODE "Executing operating system commands"
2250 .SH "Executing operating system commands"
2251 You may execute commands by typing them directly in the Midnight
2252 Commander's input line, or by selecting the program you want to
2253 execute with the selection bar in one of the panels and hitting Enter.
2255 If you press Enter over a file that is not executable, the Midnight
2256 Commander checks the extension of the selected file against the
2260 .\"Extension File Edit"
2261 If a match is found then the code associated with that extension is
2262 executed. A very simple
2265 .\"Macro Substitution"
2266 takes place before executing the command.
2267 .\"NODE " The cd internal command"
2268 .SH " The cd internal command"
2271 command is interpreted by the Midnight Commander, it is not passed to
2272 the command shell for execution. Thus it may not handle all of the
2273 nice macro expansion and substitution that your shell does, although it
2276 .I Tilde substitution.
2277 The (~) will be substituted with your home directory, if you append a
2278 username after the tilde, then it will be substituted with the login
2279 directory of the specified user.
2281 For example, ~guest is the home directory for the user guest, while
2282 ~/guest is the directory guest in your home directory.
2284 .I Previous directory.
2285 You can jump to the directory you were previously by using the special
2286 directory name '\-' like this:
2289 .I CDPATH directories.
2290 If the directory specified to the
2292 command is not in the current directory, then The Midnight Commander
2293 uses the value in the environment variable
2295 to search for the directory in any of the named directories.
2297 For example you could set your
2299 variable to ~/src:/usr/src, allowing you to change your directory to
2300 any of the directories inside the ~/src and /usr/src directories, from
2301 any place in the file system by using its relative name (for example
2302 cd linux could take you to /usr/src/linux).
2303 .\"NODE " Macro Substitution"
2304 .SH " Macro Substitution"
2311 extension dependent command\&,
2312 .\"Extension File Edit"
2313 or running a command from the command line input, a simple macro
2314 substitution takes place.
2319 The indent of blank space, equal the cursor column position. For edit
2323 The syntax type of current file. For edit menu only.
2326 The block file name.
2329 The error file name.
2332 The current menu name.
2335 The current file name.
2338 The extension of current file name.
2341 The current file name without extension.
2344 The current directory name.
2347 The current file in the unselected panel.
2350 The directory name of the unselected panel.
2353 The currently tagged files.
2356 The tagged files in the unselected panel.
2359 Similar to the %t and %T macros, but in addition the files are untagged.
2360 You can use this macro only once per menu file entry or extension file
2361 entry, because next time there will be no tagged files.
2364 The selected files: The tagged files if there are any. Otherwise the
2368 This is a special macro that is used to change the current directory
2369 to the directory specified in front of it. This is used primarily as
2372 Virtual File System\&.
2373 .\"Virtual File System"
2376 This macro is used to invoke the internal viewer. This macro can be
2377 used alone, or with arguments. If you pass any arguments to this
2378 macro, they should be enclosed in brackets.
2382 to force the viewer into ascii mode;
2384 to force the viewer into hex mode;
2386 to tell the viewer that it should interpret the bold and underline
2389 to tell the viewer to not interpret nroff commands for making the text
2396 Prompt for the substitution. An input box is shown and the text inside
2397 the braces is used as a prompt. The macro is substituted by the text
2398 typed by the user. The user can press ESC or F10 to cancel. This macro
2399 doesn't work on the command line yet.
2401 .I %var{ENV:default}
2402 If environment variable
2406 is substituted. Otherwise, the value of
2409 .\"NODE " The subshell support"
2410 .SH " The subshell support"
2411 The subshell support is a compile time option, that works with the
2412 shells: bash, tcsh and zsh.
2414 When the subshell code is activated the Midnight Commander will
2415 spawn a concurrent copy of your shell (the one defined in the
2417 variable and if it is not defined, then the one in the /etc/passwd
2418 file) and run it in a pseudo terminal, instead of invoking a new shell
2419 each time you execute a command, the command will be passed to the
2420 subshell as if you had typed it. This also allows you to change the
2421 environment variables, use shell functions and define aliases that are
2422 valid until you quit the Midnight Commander.
2426 you can specify startup
2427 commands for the subshell in your ~/.local/share/mc/bashrc file and
2428 special keyboard maps in the ~/.local/share/mc/inputrc file.
2430 users may specify startup commands in the ~/.local/share/mc/tcshrc file.
2432 When the subshell code is used, you can suspend applications at any
2433 time with the sequence C\-o and jump back to the Midnight Commander, if
2434 you interrupt an application, you will not be able to run other
2435 external commands until you quit the application you interrupted.
2437 An extra added feature of using the subshell is that the prompt
2438 displayed by the Midnight Commander is the same prompt that you are
2439 currently using in your shell.
2445 section has more information on how you can control the subshell code.
2448 The Chmod window is used to change the attribute bits in a group of
2449 files and directories. It can be invoked with the C\-x c key combination.
2451 The Chmod window has two parts \-
2456 In the File section are displayed the name of the file or directory
2457 and its permissions in octal form, as well as its owner and group.
2459 In the Permissions section there is a set of check buttons which
2460 correspond to the file attribute bits. As you change the attribute
2461 bits, you can see the octal value change in the File section.
2463 To move between the widgets (buttons and check buttons) use the
2467 key. To change the state of the check buttons or to select a button
2470 You can also use the hotkeys on the buttons to quickly activate them.
2471 Hotkeys are shown as highlighted letters on the buttons.
2473 To set the attribute bits, use the Enter key.
2475 When working with a group of files or directories, you just click on
2476 the bits you want to set or clear. Once you have selected the bits
2477 you want to change, you select one of the action buttons (Set marked
2480 Finally, to set the attributes exactly to those specified, you can use
2483 button, which will act on all the tagged files.
2486 set only marked attributes to all selected files
2489 set marked bits in attributes of all selected files
2492 clear marked bits in attributes of all selected files
2495 set the attributes of one file
2498 cancel the Chmod command
2501 The Chown command is used to change the owner/group of a file. The hot
2502 key for this command is C\-x o.
2503 .\"NODE "Advanced Chown"
2504 .SH "Advanced Chown"
2505 The Advanced Chown command is the
2513 command combined into one window. You can change the permissions and
2514 owner/group of files at once.
2515 .\"NODE "File Operations"
2516 .SH "File Operations"
2517 When you copy, move or delete files the Midnight Commander shows the
2518 file operations dialog. It shows the files currently being processed
2519 and uses up to three progress bars. The file bar indicates the
2520 percentage of the current file that has been processed so far. The
2521 count bar shows how many of the tagged files have been handled. The
2522 bytes bar indicates the percentage of the total size of the tagged files
2523 that has been handled. If the verbose option is off, the file and bytes
2526 There are two buttons at the bottom of the dialog. Pressing the Skip
2527 button will skip the rest of the current file. Pressing the Abort
2528 button will abort the whole operation, the rest of the files are
2531 There are three other dialogs which you can run into during the file
2534 The error dialog informs about error conditions and has three choices.
2535 Normally you select either the Skip button to skip the file or the Abort
2536 button to abort the operation altogether. You can also select the Retry
2537 button if you fixed the problem from another terminal.
2539 The replace dialog is shown when you attempt to copy or move a file on
2540 the top of an existing file. The dialog shows the dates and sizes of
2541 the both files. Press the Yes button to overwrite the file, the No
2542 button to skip the file, the All button to overwrite all the files, the
2543 None button to never overwrite and the Update button to overwrite if the
2544 source file is newer than the target file. You can abort the whole
2545 operation by pressing the Abort button.
2547 The recursive delete dialog is shown when you try to delete a directory
2548 which is not empty. Press the Yes button to delete the directory
2549 recursively, the No button to skip the directory, the All button to
2550 delete all the directories and the None button to skip all the non\-empty
2551 directories. You can abort the whole operation by pressing the Abort
2552 button. If you selected the Yes or All button you will be asked for a
2553 confirmation. Type "yes" only if you are really sure you want to do the
2556 If you have tagged files and perform an operation on them only the files
2557 on which the operation succeeded are untagged. Failed and skipped files
2559 .\"NODE "Mask Copy/Rename"
2560 .SH "Mask Copy/Rename"
2561 The copy/move operations let you translate the names of files in an
2562 easy way. To do it, you have to specify the correct source mask and
2563 usually in the trailing part of the destination specify some wildcards.
2564 All the files matching the source mask are copied/renamed according to
2565 the target mask. If there are tagged files, only the tagged files
2566 matching the source mask are renamed.
2568 There are other options which you can set:
2572 determines whether make the symlinks and hardlinks in the source
2573 directory (recursively in subdirectories) new links in the target
2574 directory or whether would you like to copy their content.
2576 .B Dive into subdirs
2578 determines the behavior when the source directory is about to be copied,
2579 but the target directory already exists. The default action is to copy
2580 the contents of the source directory into the target directory.
2581 Enabling this option causes copying the source directory itself into the
2584 For example, you want to copy directory
2590 which is an already existing directory. Normally (when
2591 .B Dive into subdirs
2592 is not set), mc would copy file
2596 By enabling this option the
2598 directory will be created, and
2601 .IR /bla/foo/foo/bar .
2603 .B Preserve attributes
2605 determines whether to preserve the permissions, timestamps and (if you
2606 are root) the ownership of the original files. If this option is not
2607 set, the current value of the umask will be respected.
2609 .B Use shell patterns on
2611 When the shell patterns option is on you can use the '*' and '?'
2612 wildcards in the source mask. They work like they do in the shell. In
2613 the target mask only the '*' and '\\<digit>' wildcards are allowed. The
2614 first '*' wildcard in the target mask corresponds to the first wildcard
2615 group in the source mask, the second '*' corresponds to the second group
2616 and so on. The '\\1' wildcard corresponds to the first wildcard group
2617 in the source mask, the '\\2' wildcard corresponds to the second group
2618 and so on all the way up to '\\9'. The '\\0' wildcard is the whole
2619 filename of the source file.
2623 If the source mask is "*.tar.gz", the destination is "/bla/*.tgz" and the
2624 file to be copied is "foo.tar.gz", the copy will be "foo.tgz" in "/bla".
2626 Suppose you want to swap basename and extension so that "file.c" would
2627 become "c.file" and so on. The source mask for this is "*.*" and the
2628 destination is "\\2.\\1".
2630 .B Use shell patterns off
2632 When the shell patterns option is off the MC doesn't do automatic
2633 grouping anymore. You must use '\\(...\\)' expressions in the source
2634 mask to specify meaning for the wildcards in the target mask. This is
2635 more flexible but also requires more typing. Otherwise target masks
2636 are similar to the situation when the shell patterns option is on.
2640 If the source mask is "^\\(.*\\)\\.tar\\.gz$", the destination is
2641 "/bla/*.tgz" and the file to be copied is "foo.tar.gz", the copy
2642 will be "/bla/foo.tgz".
2644 Let's suppose you want to swap basename and extension so that "file.c"
2645 will become "c.file" and so on. The source mask for this is
2646 "^\\(.*\\)\\.\\(.*\\)$" and the destination is "\\2.\\1".
2650 You can also change the case of the filenames. If you use '\\u'
2651 or '\\l' in the target mask, the next character will be converted to
2652 uppercase or lowercase correspondingly.
2654 If you use '\\U' or '\\L' in the target mask, the next characters will
2655 be converted to uppercase or lowercase correspondingly up to the
2656 next '\\E' or next '\\U', '\\L' or the end of the file name.
2658 The '\\u' and '\\l' are stronger than '\\U' and '\\L'.
2660 For example, if the source mask is '*' (shell patterns on) or '^\\(.*\\)$'
2661 (shell patterns off) and the target mask is '\\L\\u*' the file names
2662 will be converted to have initial upper case and otherwise lower case.
2664 You can also use '\\' as a quote character. For example, '\\\\' is
2665 a backslash and '\\*' is an asterisk.
2669 commands Midnight Commander, that it should change symlinks in the target,
2670 so that they'll point to the same location as it did before. With absolute
2671 symbolic links this does nothing, but if you have a relative one, it will
2672 recompute its value, adding necessary ../ and other directory parts and making
2673 the value as short as possible (most modern filesystems keep short symlinks
2674 inside inodes and thus don't waste much disk space).
2676 .\"NODE "Select/Unselect Files"
2677 .SH "Select/Unselect Files"
2678 The dialog of group of files and directories selection or uselection.
2683 allow enter the regular expression of filenames that will be
2684 selected/unselected.
2688 checkbox is on, only files will be selected. If
2690 is off, as files as directories will be selected.
2693 checkbox is on, the regular expression is much like the filename globbing
2694 in the shell (* standing for zero or more characters and ? standing
2695 for one character). If
2697 is off, then the tagging of files is done with normal regular
2698 expressions (see ed (1)). When
2700 checkbox is on, the selection will be case sensitive characters.
2703 is off, the case will be ignored.
2704 .\"NODE "Diff Viewer"
2705 .SH "Internal Diff Viewer"
2706 The mcdiff is a visual diff tool. You can compare two files and edit them
2707 in\-place (diffs are updated dynamically). You can browse and view a working
2708 copy from popular version control systems (GIT, Subversion, etc).
2710 Following shortcuts are available in internal diff viewer of Midnight
2714 Invoke the built\-in hypertext help viewer.
2717 Save modified files.
2720 Edit file of the left panel in the internal editor.
2723 Edit file of the right panel in the internal editor.
2726 Merge the current hunk. Only the current hunk will be merged.
2735 Exit from diff viewer.
2738 Toggle show of hunk status.
2741 Toggle show of line numbers.
2744 Maximize left panel.
2747 Make panels equal in width.
2750 Reduce the size of the right panel.
2753 Reduce the size of the left panel.
2756 Toggle show of trailing carriage return (CR) symbol as ^M.
2762 Swap contents of diff panels.
2768 Switch to the subshell and show the command screen.
2771 Find next diff hunk.
2774 Find previous diff hunk.
2780 Scroll one line forward.
2783 Scroll one line backward.
2792 Moves to the line beginning.
2795 Moves to the line end.
2798 Move to the file beginning.
2801 Move to the file end.
2802 .\"NODE "Internal File Viewer"
2803 .SH "Internal File Viewer"
2804 The internal file viewer provides two display modes: ASCII and hex.
2805 To toggle between modes, use the F4 key.
2807 The viewer will try to use the best method provided by your system or
2808 the file type to display the information.
2809 Some character sequences, which appear most often in preformatted manual
2810 pages, are displayed bold and underlined, thus making a pretty display
2813 When in hex mode, the search function accepts text in quotes and
2814 constant numbers. Text in quotes is matched exactly after removing
2815 the quotes. Each number matches one byte. You can mix quoted text
2816 with constants like this:
2819 "String" \-1 0xBB 012 "more text"
2822 Note that 012 is an octal number. \-1 is converted to 0xFF.
2824 Here is a listing of the actions associated with each key that the
2825 Midnight Commander handles in the internal file viewer.
2828 Invoke the built\-in hypertext help viewer.
2831 Toggle the wrap mode.
2834 Toggle the hex mode.
2837 Goto line. This will prompt you for a line number and will display
2841 Regular expression search.
2844 Reverse regular expression search.
2847 Normal search / hex mode search.
2850 Start normal search if there was no previous search expression else
2854 Start reverse search if there was no previous search expression else
2858 Toggle Raw/Parsed mode: This will show the file as found on disk or if
2859 a processing filter has been specified in the mc.ext file, then the
2860 output from the filter. Current mode is always the other than written
2861 on the button label, since on the button is the mode which you enter
2865 Toggle the format/unformat mode: when format mode is on the viewer
2866 will interpret some string sequences to show bold and underline with
2867 different colors. Also, on button label is the other mode than current.
2870 Exit the internal file viewer.
2872 .B next\-page, space, C\-v.
2873 Scroll one page forward.
2875 .B prev\-page, Alt\-v, C\-b, Backspace.
2876 Scroll one page backward.
2879 Scroll one line forward.
2882 Scroll one line backward.
2888 Switch to the subshell and show the command screen.
2891 Like C\-o, but run a new shell if the subshell is not running.
2900 Jump to the next file.
2903 Jump to the previous file.
2909 to change charset of displayed text may use M\-e (Alt\-e).
2910 Recoding is made from selected codepage into system codepage. To
2911 cancel the recoding you may select "<No translation>" in charset
2914 It's possible to instruct the file viewer how to display a file, look
2917 Extension File Edit section
2918 .\"Extension File Edit"
2920 .\"NODE "Internal File Editor"
2921 .SH "Internal File Editor"
2922 The internal file editor is a full\-featured full screen editor. It can
2923 edit files up to 64 megabytes. It is possible to edit binary files.
2924 The internal file editor is invoked using
2927 .I use_internal_edit
2928 option is set in the initialization file.
2930 The features it presently supports are: block copy, move, delete, cut,
2931 paste; key for key undo; pull\-down menus; file insertion; macro
2932 commands; regular expression search and replace; shift\-arrow text highlighting
2933 (if supported by the terminal); insert\-overwrite toggle; word wrap;
2934 autoindent; tunable tab size; syntax highlighting for various file
2935 types; and an option to pipe text blocks through shell commands like
2941 Options of editor in ini\-file
2942 .\"Internal File Editor / options"
2944 The editor is very easy to use and requires no tutoring. To see what
2945 keys do what, just consult the appropriate pull\-down menu. Other keys
2946 are: Shift movement keys do text highlighting.
2952 pastes from mcedit.clip.
2958 deletes highlighted text. Mouse highlighting also works, and you
2959 can override the mouse as usual by holding down the shift key
2960 while dragging the mouse to let normal terminal mouse highlighting
2963 To define a macro, press
2965 and then type out the key
2966 strokes you want to be executed. Press
2968 again when finished. You can then assign the macro to any key you
2969 like by pressing that key. The macro is executed when you press
2971 and then the assigned key. The macro is also executed if
2972 you press Meta, Ctrl, or Esc and the assigned key, provided that the
2973 key is not used for any other function. Once defined, the macro
2974 commands go into the file
2975 .B ~/.local/share/mc/mcedit/mcedit.macros
2976 You can delete a macro by deleting the
2977 appropriate line in this file.
2979 To change charset of displayed text may use M\-e (Alt\-e).
2980 Recoding is made from selected codepage into system codepage. To
2981 cancel the recoding you may select "<No translation>" in charset
2985 will format the currently highlighted block (plain text or
2989 code or another). This is controlled by the
2991 .B @prefix@/share/mc/edit.indent.rc
2993 .B ~/.local/share/mc/mcedit/edit.indent.rc
2994 in your home directory the first time you use it.
2996 The editor also displays non\-us characters (160+). When editing
2997 binary files, you should set
2999 to 7 bits in the options menu to keep the spacing clean.
3001 .\"NODE "Internal File Editor / options"
3002 .SH "Options of editor in ini\-file"
3004 Some editor options of ini\-file are described in this section.
3005 Options are placed in [Midnight\-Commander] section
3007 .I editor_wordcompletion_collect_entire_file
3008 Search autocomplete candidates in entire of file or just from
3009 begin of file to cursor position (0)
3011 .\"NODE "Screen selector"
3012 .SH "Screen selector"
3013 Midnight Commander supports running many internal modules (such as
3014 editor, viewer and diff viewer) simultaneously and switching between
3015 them without closing open files. Using several file managers at a time,
3016 however, is not currently supported.
3018 Let's call each of these modules a screen. There are three ways to
3019 switch between screens, using one of these global shortcuts:
3022 switch to the next screen;
3025 switch to the previous screen;
3028 open a dialog window with the list of currently open screens (or use the
3029 "Screen list" menu item).
3030 .\"NODE "Completion"
3032 Let the Midnight Commander type for you.
3034 Attempt to perform completion on the text before current position. MC
3035 attempts completion treating the text as variable (if the text begins
3038 username (if the text begins with
3040 hostname (if the text begins with
3042 or command (if you are on the command line in the position where you
3043 might type a command, possible completions then include shell reserved
3044 words and shell built\-in commands as well) in turn. If none of these
3045 matches, filename completion is attempted.
3047 Filename, username, variable and hostname completion works on all input
3048 lines, command completion is command line specific. If the completion
3049 is ambiguous (there are more different possibilities), MC beeps and the
3050 following action depends on the setting of the
3051 .I Complete: show all
3056 dialog. If it is enabled, a list of all possibilities pops up next to
3057 the current position and you can select with the arrow keys and
3059 the correct entry. You can also type the first letters in which the
3060 possibilities differ to move to a subset of all possibilities and
3061 complete as much as possible. If you press
3063 again, only the subset will be shown in the listbox, otherwise the first
3064 item which matches all the previous characters will be highlighted. As
3065 soon as there is no ambiguity, dialog disappears, but you can hide it by
3069 and left and right arrow keys. If
3073 is disabled, the dialog pops up only if you press
3075 for the second time, for the first time MC just beeps.
3076 .\"NODE "Virtual File System"
3077 .SH "Virtual File System"
3078 The Midnight Commander is provided with a code layer to access the file
3079 system; this code layer is known as the virtual file system switch. The
3080 virtual file system switch allows the Midnight Commander to manipulate
3081 files not located on the Unix file system.
3083 Currently the Midnight Commander is packaged with some Virtual File
3086 file system, used for accessing the regular Unix file system; the
3088 used to manipulate files on remote systems with the FTP protocol; the
3090 used to manipulate tar and compressed tar files; the
3092 used to recover deleted files on ext2 file systems (the default file
3093 system for Linux systems),
3095 (for manipulating files over shell connections such as rsh and ssh).
3096 If the code was compiled with
3098 support, you can manipulate files on remote systems with the SMB (CIFS)
3103 (EXTernal virtual File System) is provided in order to easily expand
3104 VFS capabilities using scripts and external software.
3106 The VFS switch code will interpret all of the path names used and will
3107 forward them to the correct file system, the formats used for each one
3108 of the file systems is described later in their own section.
3109 .\"NODE " FTP File System"
3110 .SH " FTP File System"
3111 The FTP File System (ftpfs) allows you to manipulate files on remote
3112 machines. To actually use it, you can use the
3114 item in the menu or directly change your current directory using the
3116 command to a path name that looks like this:
3118 .I ftp://[!][user[:pass]@]machine[:port][remote\-dir]
3125 elements are optional. If you specify the
3127 element, the Midnight Commander will login to the remote machine as that
3128 user, otherwise it will use anonymous login or the login name from the
3132 element is the password used for the connection. Using the password in
3133 the VFS directory name is not recommended, because it can appear on the
3134 screen in clear text and can be saved to the directory history.
3136 To enable using FTP proxy, prepend
3138 (an exclamation sign) to the hostname.
3143 ftp://ftp.nuclecu.unam.mx/linux/local
3144 ftp://tsx\-11.mit.edu/pub/linux/packages
3145 ftp://!behind.firewall.edu/pub
3146 ftp://guest@remote\-host.com:40/pub
3147 ftp://miguel:xxx@server/pub
3154 dialog box for ftpfs options.
3155 .\"NODE " Tar File System"
3156 .SH " Tar File System"
3157 The tar file system provides you with read\-only access to your tar
3158 files and compressed tar files by using the chdir command. To change
3159 your directory to a tar file, you change your current directory to the
3160 tar file by using the following syntax:
3162 .I /filename.tar/utar://[dir\-inside\-tar]
3164 The mc.ext file already provides a shortcut for tar files, this means
3165 that usually you just point to a tar file and press return to enter
3166 into the tar file, see the
3169 .\"Extension File Edit"
3170 section for details on how this is done.
3175 mc\-3.0.tar.gz/utar://mc\-3.0/vfs
3176 /ftp/GCC/gcc\-2.7.0.tar/utar://
3179 The latter specifies the full path of the tar archive.
3180 .\"NODE " FIle transfer over SHell filesystem"
3181 .SH " FIle transfer over SHell filesystem"
3182 The fish file system is a network based file system that allows you to
3183 manipulate the files in a remote machine as if they were local. To use
3184 this, the other side has to either run fish server, or has to have
3185 bash\-compatible shell.
3187 To connect to a remote machine, you just need to chdir
3188 into a special directory which name is in the following
3191 .I sh://[user@]machine[:options]/[remote\-dir]
3198 elements are optional. If you specify the
3200 element, the Midnight Commander will try to login on the remote
3201 machine as that user, otherwise it will use your login name.
3207 'C' \- use compression;
3208 'r' \- use rsh instead of ssh;
3209 port \- specify the port used by remote server.
3213 element is present, your current directory on the remote machine will be
3219 sh://onlyrsh.mx:r/linux/local
3220 sh://joe@want.compression.edu:C/private
3221 sh://joe@noncompressed.ssh.edu/private
3222 sh://joe@somehost.ssh.edu:2222/private
3224 .\"NODE " Undelete File System"
3225 .SH " Undelete File System"
3226 On Linux systems, if you asked configure to use the ext2fs undelete
3227 facilities, you will have the undelete file system available.
3228 Recovery of deleted files is only available on ext2 file systems. The
3229 undelete file system is just an interface to the ext2fs library to
3230 retrieve all of the deleted files names on an ext2fs and provides and
3231 to extract the selected files into a regular partition.
3233 To use this file system, you have to chdir into the special file name
3234 formed by the "undel://" prefix and the file name where the actual
3235 file system resides.
3237 For example, to recover deleted files on the second partition of the
3238 first SCSI disk on Linux, you would use the following path name:
3244 It may take a while for the undelfs to load the required information
3245 before you start browsing files there.
3246 .\"NODE " SMB File System"
3247 .SH " SMB File System"
3248 The smbfs allows you to manipulate files on remote machines with SMB
3249 (or CIFS) protocol. These include Windows for Workgroups,
3250 Windows 9x/ME/XP, Windows NT, Windows 2000 and Samba.
3251 To actually use it, you may try to use the panel command "SMB link..."
3252 (accessible from the menubar) or you may directly change your current
3253 directory to it using the cd command to a path name that looks like this:
3255 .I smb://[user@]machine[/service][/remote\-dir]
3262 elements are optional.
3268 can be specified in an input dialog.
3275 smb://guest@machine/Public/Irlex
3277 .\"NODE " EXTernal File System"
3278 .SH " EXTernal File System"
3280 allows to integrate numerous features and file types into GNU Midnight
3281 Commander in an easy way, by writing scripts.
3283 Extfs filesystems can be divided into two categories:
3285 1. Stand\-alone filesystems, which are not associated with any existing
3286 file. They represent certain system\-wide data as a directory tree.
3287 You can invoke them by typing
3288 .RI ' "cd fsname://" '
3289 where fsname is an extfs short name (see below). Examples of such
3290 filesystems include audio (list audio tracks on the CD) or apt (list of
3291 all Debian packages in the system).
3293 For example, to list CD\-Audio tracks on your CD\-ROM drive, type
3299 2. 'Archive' filesystems (like rpm, patchfs and more), which represent
3300 contents of a file as a directory tree. It can consist of 'real' files
3301 compressed in an archive (urar, rpm) or virtual files, like messages
3302 in a mailbox (mailfs) or parts of a patch (patchfs). To access such
3305 should be appended to the archive name. Note that the archive itself
3306 can be on another vfs.
3308 For example, to list contents of a zip archive documents.zip type
3311 cd documents.zip/uzip://
3314 In many aspects, you could treat extfs like any other directory. For
3315 instance, you can add it to the hotlist or change to it from directory
3316 history. An important limitation is that you cannot invoke shell
3317 commands inside extfs, just like any other non\-local VFS.
3319 Common extfs scripts included with Midnight Commander are:
3322 access 'A:' DOS/Windows diskette
3326 front end to Debian's APT package management system
3327 .RI ( "cd apt://" ).
3330 audio CD ripping and playing
3333 .IR "cd device/audio://" ).
3336 package of Bad Penguin GNU/Linux distribution
3337 .RI ( "cd file.bpp/bpp://" ).
3340 package of Debian GNU/Linux distribution
3341 .RI ( "cd file.deb/deb://" ).
3344 Debian GNU/Linux installed packages
3345 .RI ( "cd deb://" ).
3348 view and copy files to/from a HP48 calculator
3349 .RI ( "cd hp48://" ).
3352 browsing of lslR listings as found on many FTPs
3353 .RI ( "cd filename/lslR://" ).
3356 mbox\-style mailbox files support
3357 .RI ( "cd mailbox/mailfs://" ).
3360 extfs to handle unified and context diffs
3361 .RI ( "cd filename/patchfs://" ).
3365 .RI ( "cd filename/rpm://" ).
3368 RPM database management
3369 .RI ( "cd rpms://" ).
3371 .B ulha, urar, uzip, uzoo, uar, uha
3373 .RI ( "cd archive/xxxx://"
3374 where xxxx is one of:
3382 You could bind file type/extension to specified extfs as described in the
3385 .\"Extension File Edit"
3386 section. Here is an example entry for Debian packages:
3394 The Midnight Commander will try to detect if your terminal supports
3395 color using the terminal database and your terminal name. Sometimes
3396 it gets confused, so you may force color mode or disable color mode
3397 using the \-c and \-b flag respectively.
3399 If the program is compiled with the Slang screen manager instead of
3400 ncurses, it will also check the variable
3402 if it is set, it has the same effect as the \-c flag.
3404 You may specify terminals that always force color mode
3407 variable to the Colors section of the initialization file. This will
3408 prevent the Midnight Commander from trying to detect if your terminal
3409 supports color. Example:
3413 color_terminals=linux,xterm
3414 color_terminals=terminal\-name1,terminal\-name2...
3417 The program can be compiled with both ncurses and slang, ncurses does
3418 not provide a way to force color mode: ncurses uses just the
3419 information in the terminal database.
3421 The Midnight Commander provides a way to change the default colors.
3422 Currently the colors are configured using the environment variable
3424 or the Colors section in the initialization file.
3426 In the Colors section, the default color map is loaded from the
3428 variable. You can specify an alternate color map for a terminal by
3429 using the terminal name as the key in this section. Example:
3434 xterm=menu=magenta:marked=,magenta:markselect=,red
3437 The format for the color definition is:
3440 <keyword>=<fgcolor>,<bgcolor>,<attributes>:<keyword>=...
3443 The colors are optional, and the keywords are: normal, selected, disabled, marked,
3444 markselect, errors, input, inputmark, inputunchanged, commandlinemark,
3445 reverse, gauge, header, inputhistory, commandhistory. Button bar colors are:
3446 bbarhotkey, bbarbutton. Status bar color: statusbar. Menu colors are: menunormal,
3447 menusel, menuhot, menuhotsel, menuinactive. Dialog colors are: dnormal, dfocus,
3448 dhotnormal, dhotfocus, dtitle. Error dialog colors are: errdfocus, errdhotnormal,
3449 errdhotfocus, errdtitle. Help colors are: helpnormal, helpitalic, helpbold,
3450 helplink, helpslink, helptitle. Viewer color are: viewbold, viewunderline, viewselected.
3451 Editor colors are: editnormal, editbold, editmarked, editwhitespace, editlinestate.
3452 Popup menu colors are: pmenunormal, pmenusel, pmenutitle.
3455 determines the color of panel header, the line that contains column titles
3456 and sort mode indicator.
3459 determines the color of input lines used in query dialogs.
3462 determines the color of the filled part of the progress bar (gauge),
3463 which is used to show the user the progress of file operations, such as
3467 determines the color of the widget that cannot be selected.
3469 The dialog boxes use the following colors:
3471 is used for the normal text,
3473 is the color used for the currently selected component,
3475 is the color used to differentiate the hotkey color in normal
3476 components, whereas the
3478 color is used for the highlighted color in the currently selected
3481 Menus use the same scheme but uses the menunormal, menusel, menuhot, menuhotsel
3482 and menuinactive tags instead.
3484 Help uses the following colors:
3486 is used for normal text,
3488 is used for text which is emphasized in italic in the manual page,
3490 is used for text which is emphasized in bold in the manual page,
3492 is used for not selected hyperlinks and
3494 is used for selected hyperlink.
3496 Popup menu uses following colors:
3498 is used for non-selected menu items and as a main color of popup menu window,
3500 is used for selected menu item,
3502 is used for popup menu title.
3504 The possible colors are: black, gray, red, brightred, green,
3505 brightgreen, brown, yellow, blue, brightblue, magenta, brightmagenta,
3506 cyan, brightcyan, lightgray and white. And there is a special keyword
3507 for transparent background. It is 'default'. The 'default' can only be
3508 used for background color. Another special keyword "base" means mc's main
3509 colors. When 256 colors are available, they can be specified either as
3510 color16 to color255, or as rgb000 to rgb555 and gray0 to gray23. Example:
3514 base_color=normal=white,default:marked=magenta,default
3517 Attributes can be any of bold, underline, reverse and blink, appended by a
3518 plus sign if more than one are desired. The special word "none" means no
3519 attributes, without attempting to fall back to base_color. Example:
3522 menuhotsel=yellow;black;bold+underline
3527 You can change the appearance of Midnight Commander.
3528 To do this, you must specify a file that contain descriptions of colors
3529 and lines to draw boxes. Redefining of the colors is entirely compatible
3530 with the assignment of colors, as described in Section
3535 If your skin contains any of 256\-color definitions, you should define the
3536 '256colors' key set to TRUE value in [skin] section.
3539 A skin\-file is searched on the following algorithm (to the first one found):
3542 1) command line option
3545 .B \-\-skin=\<skin\>
3547 2) Environment variable
3553 .B [Midnight\-Commander]
3557 .B @sysconfdir@/mc/skins/default.ini
3560 .B @prefix@/share/mc/skins/default.ini
3563 Command line option, environment variable and parameter in config file may
3564 contain the absolute path to the skin\-file (with the extension \.ini
3565 or without it). Search of skin\-file will occur in (to the first one found):
3568 .B ~/.local/share/mc/skins/
3571 .B @sysconfdir@/mc/skins/
3574 .B @prefix@/share/mc/skins/
3578 For getting extended info, refer to:
3581 Description of section and parameters
3585 Color pair definitions
3597 .\"NODE " Skins sections"
3598 .SH " Description of section and parameters"
3602 contain metainfo for skin\-file. Parameter
3604 contain short text about skin.
3609 contain descriptions of color pairs for filenames highlighting.
3610 Name of parameters must be equal to names of sections into
3611 filehighlight.ini file.
3615 .\"Filenames Highlight"
3616 for getting more info.
3621 describes the elements that are used everywhere.
3624 Default color pair. Used in all other sections if they not contain
3634 cursor on selected data
3637 color of the filled part of the progress bar
3640 color of input lines used in query dialogs
3643 color of input selected text
3646 color of input text before first modification or cursor movement
3649 color of selected text in command line
3656 describes the elements that are placed on dialog windows (except error dialogs).
3659 Default color for this section. Used [core]._default_ if not specified
3662 Color of active element (in focus)
3668 Color of hotkeys in focused element
3673 describes the elements that are placed on error dialog windows
3676 Default color for this section. Used [core]._default_ if not specified
3682 Color of hotkeys in focused element
3687 describes the elements that are placed in menu. This section describes
3688 system menu (called by F9) and user\-defined menus (called by F2 in panels
3689 and by F11 in editor).
3692 Default color for this section. Used [core]._default_ if not specified
3698 Color of menu hotkeys
3701 Color of active menu item (in focus)
3704 Color of menu hotkeys in focused menu item
3707 Color of inactive menu
3712 describes the elements that are placed on help window.
3715 Default color for this section. Used [core]._default_ if not specified
3718 Color pair for element with
3723 Color pair for element with
3731 Color of active link (on focus)
3736 describes the colors of elements placed in editor.
3739 Default color for this section. Used [core]._default_ if not specified
3742 Color pair for element with
3747 Color of selected text
3750 Color of tabs and trailing spaces highlighting
3753 Color for line state area
3758 describes the colors of elements placed in viewer.
3761 Color pair for element with
3765 .\"NODE " Skins colors"
3766 .SH " Color pair definitions"
3767 Any parameter in skin\-file contain definition of color pair.
3769 Color pairs described as two colors and the optional attributes
3770 separated by ';'. First field sets the foreground color, second
3771 field sets background color, third field sets the attributes.
3772 Any of the fields may be omitted, in this case value will be
3773 taken from default color pair (global color pair or from default
3774 color pair of this section).
3781 _default_=green;black
3782 # green (default) on blue
3784 # yellow on black (default)
3785 # underlined yellow on black (default)
3786 marked=yellow;;underline
3790 Possible colors (names) and attributes are described in
3796 .\"NODE " Skins lines"
3798 Lines sets in section
3800 into skin\-file. By default single lines are used, but you may redefine
3801 to usage of any utf\-8 symbols (like to lines, for example).
3804 When you build Midnight Commander with the Ncurses screen library
3805 usage of drawing lines is limited!
3806 Possible only drawing a single lines.
3807 For all questions and comments please contact the developers of Ncurses.
3810 Descriptions of parameters
3814 left\-top line fragment.
3817 right\-top line fragment.
3820 down branch of horizontal line
3823 up branch of horizontal line
3826 left\-bottom line fragment
3829 right\-bottom line fragment
3832 right branch of vertical line
3835 left branch of vertical line
3847 thin horizontal line
3853 .\"NODE " Skins oldcolors"
3854 .SH " Compatibility"
3856 Appointment of color by skin\-files fully compatible with
3857 the appointment of the colors described in
3863 In this case, reassignment of colors has priority over the skin file and is
3866 .\"NODE "Filenames Highlight"
3867 .SH "Filenames Highlight"
3868 Section [filehighlight] in current skin\-file contains key names as
3869 highlight groups and values as color pairs. Color pairs is documented
3876 Rules of filenames highlight are placed in @prefix@/share/mc/filehighlight.ini file
3877 (~/.config/mc/filehighlight.ini).
3878 Name of section in this file must be equal to parameters names in
3879 [filehighlight] section (in current skin\-file).
3881 Keys in these groups are:
3884 file type. If present, all other options are ignored.
3887 regular expression. If present, 'extensions' option is ignored.
3890 list of extensions of files. Separated by ';' sign.
3893 (make sense only with 'extensions' parameter) make 'extensions'
3894 rule case sentitive (true) or not (false).
3896 `type' key may have values:
3900 \- DIR (all directories)
3902 \- LINK (all links except stale link)
3906 \- DEVICE (all device files)
3909 \- SPECIAL (all special files)
3916 .\"NODE "Special Settings"
3917 .SH "Special Settings"
3918 Most of the Midnight Commander settings can be changed from the
3919 menus. However, there are a small number of settings which can only be
3920 changed by editing the setup file.
3922 These variables may be set in your ~/.config/mc/ini file:
3924 .I clear_before_exec
3925 By default the Midnight Commander clears the screen before executing a
3926 command. If you would prefer to see the output of the command at the
3927 bottom of the screen, edit your ~/.config/mc/ini file and change the value of
3928 the field clear_before_exec to 0.
3931 If you press F3 on a directory, normally MC enters that directory. If
3932 this flag is set to 1, then MC will ask for confirmation before changing
3933 the directory if you have files tagged.
3935 .I ftpfs_retry_seconds
3936 This value is the number of seconds the Midnight Commander will wait
3937 before attempting to reconnect to an FTP server that has denied the
3938 login. If the value is zero, the login will no be retried.
3941 Specifies how many screen updates can be skipped at most in the internal
3942 file viewer. Normally this value is not significant, because the code
3943 automatically adjusts the number of updates to skip according to the
3944 rate of incoming keystrokes. However, on very slow machines or
3945 terminals with a fast keyboard auto repeat, a big value can make screen
3948 It seems that setting max_dirt_limit to 10 causes the best behavior,
3949 and that is the default value.
3951 .I mouse_move_pages_viewer
3952 Controls if scrolling with the mouse is done by pages or line by line
3953 on the internal file viewer.
3955 .I only_leading_plus_minus
3956 Allow special treatment for '+', '\-', '*' in the command line (select,
3957 unselect, reverse selection) only if the command line is empty. You
3958 don't need to quote those characters in the middle of the command line.
3959 On the other hand, you cannot use them to change selection when the
3960 command line is not empty.
3962 .I show_output_starts_shell
3963 This variable only works if you are not using the subshell support.
3964 When you use the C\-o keystroke to go back to the user screen, if this
3965 one is set, you will get a fresh shell. Otherwise, pressing any key
3966 will bring you back to the Midnight Commander.
3968 .I timeformat_recent
3969 Change the time format used to display dates less than 6 months from
3971 See strftime or date man page for the format specification. If this
3972 option is absent, default timeformat is used.
3975 Change the time format used to display dates older than 6 months from
3976 now or for dates in the future.
3977 See strftime or date man page for the format specification. If this
3978 option is absent, default timeformat is used.
3981 If this flag is set, then the home and end keys will work slightly
3982 different on the panels, instead of moving the selection to the first
3983 and last files in the panels, they will act as follows:
3985 The home key will: Go up to the middle line, if below it; else go to the
3986 top line unless it is already on the top line, in this case it will go
3987 to the first file in the panel.
3989 The end key has a similar behavior: Go down to the middle line, if over
3990 it; else go to the bottom line unless you already are at the bottom
3991 line, in such case it will move the selection to the last file name in
3994 .I use_file_to_guess_type
3995 If this variable is on (the default) it will spawn the file command to
3996 match the file types listed on the
3999 .\"Extension File Edit"
4002 If this variable is on (default is off) when you browse the file system
4003 on a Tree panel, it will automatically reload the other panel with the
4004 contents of the selected directory.
4006 .I fish_directory_timeout
4007 This variable holds the lifetime of a directory cache entry in seconds. The
4008 default value is 900 seconds.
4011 This variable contains path (with options) to the external clipboard
4012 utility like 'xclip' to read text into X selection from file.
4016 clipboard_store=xclip \-i
4020 This variable contains path (with options) to the external clipboard
4021 utility like 'xclip' to print the selection to standard out.
4025 clipboard_pastee=xclip \-o
4028 .I autodetect_codeset
4029 This option allows use the `enca' command to autodetect codeset of text files
4030 in internal viewer and editor. List of valid values can be obtain by the
4031 `enca \-\-list languages | cut \-d : \-f1' command. Option must be located
4032 in the [Misc] section.
4037 autodetect_codeset=russian
4039 .\"NODE "Terminal databases"
4040 .SH "Terminal databases"
4041 The Midnight Commander provides a way to fix your system terminal
4042 database without requiring root privileges. The Midnight Commander
4043 searches in the system initialization file (the mc.lib file located in
4044 the Midnight Commander library directory) and in the
4045 ~/.config/mc/ini file for the section
4046 "terminal:your\-terminal\-name" and then for the section
4047 "terminal:general", each line of the section contains a key symbol that
4048 you want to define, followed by an equal sign and the definition for the
4049 key. You can use the special \\e form to represent the escape character
4050 and the ^x to represent the control\-x character.
4052 The possible key symbols are:
4055 f0 to f20 Function keys f0\-f20
4062 right right arrow key
4065 insert the insert character
4066 delete the delete character
4067 complete to do completion
4070 For example, to define the key insert to be the Escape + [ + O + p, you
4071 set this in the ini file:
4078 Also now you can use
4079 .I extended learn keys.
4083 ctrl\-alt\-right=\\e[[1;6C
4084 ctrl\-alt\-left=\\e[[1;6D
4088 This means that ctrl+alt+left sends a \\e[[1;6D escape sequence
4089 and therefore Midnight Commander interprets "\\e[[1;6D" as Ctrl\-Alt\-Left.
4094 key symbol represents the escape sequences used to invoke the completion
4095 process, this is invoked with Alt\-tab, but you can define other keys to do
4096 the same work (on those keyboard with tons of nice and unused keys
4101 Full paths below may vary between installations. They are also affected
4102 by the MC_DATADIR environment variable. If it's set, its value is used
4103 instead of @prefix@/share/mc in the paths below.
4105 .I @prefix@/share/mc/mc.hlp
4107 The help file for the program.
4109 .I @prefix@/share/mc/mc.ext
4111 The default system\-wide extensions file.
4113 .I ~/.local/share/mc/mc.ext
4115 User's own extension, view configuration and edit configuration
4116 file. They override the contents of the system wide files if present.
4118 .I @prefix@/share/mc/mc.ini
4120 The default system\-wide setup for the Midnight Commander, used only if
4121 the user doesn't have his own ~/.config/mc/ini file.
4123 .I @prefix@/share/mc/mc.lib
4125 Global settings for the Midnight Commander. Settings in this file
4126 affect all users, whether they have ~/.config/mc/ini or not. Currently, only
4129 .\"Terminal databases"
4130 are loaded from mc.lib.
4134 User's own setup. If this file is present then the setup is loaded
4135 from here instead of the system\-wide startup file.
4137 .I @prefix@/share/mc/mc.hint
4139 This file contains the hints displayed by the program.
4141 .I @prefix@/share/mc/mc.menu
4143 This file contains the default system\-wide applications menu.
4145 .I ~/.local/share/mc/menu
4147 User's own application menu. If this file is present it is used instead
4148 of the system\-wide applications menu.
4152 The directory list for the directory tree and tree view features.
4154 .I ~/.local/share/mc.menu
4156 Local user\-defined menu. If this file is present, it is used instead of
4157 the home or system\-wide applications menu.
4160 This program is distributed under the terms of the GNU General Public
4161 License as published by the Free Software Foundation. See the built\-in
4162 help for details on the License and the lack of warranty.
4163 .\"NODE "AVAILABILITY"
4165 The latest version of this program can be found at
4166 ftp://ftp.gnu.org/gnu/mc/.
4169 ed(1), gpm(1), terminfo(1), view(1), sh(1), bash(1),
4173 The Midnight Commander page on the World Wide Web:
4174 http://www.midnight\-commander.org/
4178 Authors and contributors are listed in the AUTHORS file in the source
4182 See the file TODO in the distribution for information on what remains to
4185 If you want to report a problem with the program, please send mail to
4186 this address: mc\-devel@gnome.org.
4188 Provide a detailed description of the bug, the version of the program
4191 displays this information), the operating system you are running the
4192 program on. If the program crashes, we would appreciate a stack trace.