1MC(1)                       GNU Midnight Commander                       MC(1)
2
3
4

NAME

6       mc - Visual shell for Unix-like systems.
7

USAGE

9       mc [-abcCdfhPstuUVx] [-l log] [dir1 [dir2]] [-e [file] ...] [-v file]
10

DESCRIPTION

12       GNU   Midnight  Commander  is  a  directory  browser/file  manager  for
13       Unix-like operating systems.
14

OPTIONS

16       -a, --stickchars
17              Disable usage of graphic characters for line drawing.
18
19       -b, --nocolor
20              Force black and white display.
21
22       -c, --color
23              Force color mode, please  check  the  section  Colors  for  more
24              information.
25
26       -C arg, --colors=arg
27              Specify  a  different color set in the command line.  The format
28              of arg is documented in the Colors section.
29
30       -S arg, --skin=arg
31              Specify a name of skin in the command line. Technology of  skins
32              is documented in the Skins section.
33
34       -d, --nomouse
35              Disable mouse support.
36
37       -e [file], --edit[=file]
38              Start the internal editor.  If the file is specified, open it on
39              startup.  See also mcedit (1).
40
41       -f, --datadir
42              Display the compiled-in  search  paths  for  Midnight  Commander
43              files.
44
45       -F, --datadir-info
46              Display  extended info about compiled-in paths for Midnight Com‐
47              mander.
48
49       --configure-options
50              Display configure options.
51
52       -k, --resetsoft
53              Reset softkeys to their default from the termcap/terminfo  data‐
54              base.  Only  useful on HP terminals when the function keys don't
55              work.
56
57       -K file, --keymap=file
58              Specify a name of keymap file in the command line.
59
60       --nokeymap
61              Don't load key bindings from any  file,  use  default  hardcoded
62              keys.
63
64       -l file, --ftplog=file
65              Save the ftpfs dialog with the server in file.
66
67       -D N, --debuglevel=N
68              Save the debug level for SMB VFS. N is in 0-10 range.
69
70       -P file, --printwd=file
71              Print  the  last  working directory to the specified file.  This
72              option is not meant to be used  directly.   Instead,  it's  used
73              from  a special shell script that automatically changes the cur‐
74              rent directory of the shell to the last directory  the  Midnight
75              Commander was in.  Source the file /usr/share/mc/bin/mc.sh (bash
76              and zsh users) or /usr/share/mc/bin/mc.csh (tcsh users)  respec‐
77              tively to define mc as an alias to the appropriate shell script.
78
79       -s, --slow
80              Set  alternative  mode  drawing  of  frameworks.  If the section
81              [Lines] is not filled, the symbol for the  pseudographics  frame
82              is  a  space, otherwise the frame characters are taken from fol‐
83              lowing parameters.
84
85              You can redefine the following variables:
86
87       lefttop
88              left-top corner
89
90       righttop
91              right-top corner
92
93       centertop
94              center-top cross
95
96       centerbottom
97              center-bottom cross
98
99       leftbottom
100              left-bottom corner
101
102       rightbottom
103              right-bottom corner
104
105       leftmiddle
106              left-middle cross
107
108       rightmiddle
109              right-middle cross
110
111       centermiddle
112              center cross
113
114       horiz  default horizontal line
115
116       vert   default vertical line
117
118       thinhoriz
119              thin horizontal line
120
121       thinvert
122              thin vertical line
123
124       -t, --termcap
125              Used only if the code was compiled with Slang and  terminfo:  it
126              makes  the Midnight Commander use the value of the TERMCAP vari‐
127              able for the terminal information instead of the information  on
128              the system wide terminal database
129
130       -u, --nosubshell
131              Disable  use  of  the  concurrent shell (only makes sense if the
132              Midnight Commander has been built  with  concurrent  shell  sup‐
133              port).
134
135       -U, --subshell
136              Enable  use of the concurrent shell support (only makes sense if
137              the Midnight Commander was built with the subshell  support  set
138              as an optional feature).
139
140       -v file, --view=file
141              Start  the internal viewer to view the specified file.  See also
142              mcview (1).
143
144       -V, --version
145              Display the version of the program.
146
147       -x, --xterm
148              Force xterm mode.  Used when running on xterm-capable  terminals
149              (two screen modes, and able to send mouse escape sequences).
150
151       -X, --no-x11
152              Do not use X11 to get the state of modifiers Alt, Ctrl, Shift
153
154       -g, --oldmouse
155              Force  a  "normal  tracking"  mouse  mode.  Used when running on
156              xterm-capable terminals (tmux/screen).
157
158       If specified, the first path name is  the  directory  to  show  in  the
159       selected  panel;  the  second path name is the directory to be shown in
160       the other panel.
161

Overview

163       The screen of the  Midnight  Commander  is  divided  into  four  parts.
164       Almost all of the screen space is taken up by two directory panels.  By
165       default, the second line from the bottom of the  screen  is  the  shell
166       command  line,  and the bottom line shows the function key labels.  The
167       topmost line is the menu bar line.  The menu bar line may not be  visi‐
168       ble,  but appears if you click the topmost line with the mouse or press
169       the F9 key.
170
171       The Midnight Commander provides a view of two directories at  the  same
172       time. One of the panels is the current panel (a selection bar is in the
173       current panel). Almost all operations take place on the current  panel.
174       Some  file operations like Rename and Copy by default use the directory
175       of the unselected panel as a destination (don't worry, they always  ask
176       you  for confirmation first). For more information, see the sections on
177       the Directory Panels, the Left and Right Menus and the File Menu.
178
179       You can execute system commands from the Midnight Commander  by  simply
180       typing them. Everything you type will appear on the shell command line,
181       and when you press Enter the Midnight Commander will execute  the  com‐
182       mand  line  you  typed; read the Shell Command Line and Input Line Keys
183       sections to learn more about the command line.
184

Mouse Support

186       The Midnight Commander comes with mouse support.  It is activated when‐
187       ever you are running on an xterm(1) terminal (it even works if you take
188       a telnet, ssh or rlogin connection to another machine from  the  xterm)
189       or  if you are running on a Linux console and have the gpm mouse server
190       running.
191
192       When you left click on a file in the directory  panels,  that  file  is
193       selected;  if  you  click with the right button, the file is marked (or
194       unmarked, depending on the previous state).
195
196       Double-clicking on a file will try to execute the command if it  is  an
197       executable  program;  and if the extension file has a program specified
198       for the file's extension, the specified program is executed.
199
200       Also, it is possible to execute the commands assigned to  the  function
201       key labels by clicking on them.
202
203       The default auto repeat rate for the mouse buttons is 400 milliseconds.
204       This may be changed to other values  by  editing  the  ~/.config/mc/ini
205       file and changing the mouse_repeat_rate parameter.
206
207       If  you  are running the Midnight Commander with the mouse support, you
208       can get the default mouse behavior (cutting and pasting text) by  hold‐
209       ing down the Shift key.
210
211

Keys

213       Some  commands in the Midnight Commander involve the use of the Control
214       (sometimes labeled CTRL or CTL) and the Meta (sometimes labeled ALT  or
215       even  Compose) keys. In this manual we will use the following abbrevia‐
216       tions:
217
218       C-<chr>
219              means hold the Control key while  typing  the  character  <chr>.
220              Thus C-f would be: hold the Control key and type f.
221
222       Alt-<chr>
223              means  hold  the  Meta  or  Alt key down while typing <chr>.  If
224              there is no Meta or Alt key, type ESC, release it, then type the
225              character <chr>.
226
227       S-<chr>
228              means hold the Shift key down while typing <chr>.
229
230       All  input  lines in the Midnight Commander use an approximation to the
231       GNU Emacs editor's key bindings (default).
232
233       You may redefine key bindings. See redefine hotkey bindings
234
235       for more info. All other key bindings (described in this manual)  rela‐
236       tive to default behavior.
237
238
239       There  are  many  sections which tell about the keys. The following are
240       the most important.
241
242       The File Menu section documents the keyboard shortcuts for the commands
243       appearing  in  the  File menu. This section includes the function keys.
244       Most of these commands perform some action,  usually  on  the  selected
245       file or the tagged files.
246
247       The  Directory Panels section documents the keys which select a file or
248       tag files as a target for a later action (the  action  is  usually  one
249       from the file menu).
250
251       The  Shell Command Line section list the keys which are used for enter‐
252       ing and editing command lines. Most of these copy file names  and  such
253       from  the directory panels to the command line (to avoid excessive typ‐
254       ing) or access the command line history.
255
256       Input Line Keys are used for editing input lines. This means  both  the
257       command line and the input lines in the query dialogs.
258
259
260  Redefine hotkey bindings
261       Hotkey  bindings  may  be  read from external file (keymap-file).  Ini‐
262       tially, Mignight Commander creates key bindings using keymap defined in
263       the   source   code.   Then,   two  files  /usr/share/mc/mc.keymap  and
264       /etc/mc/mc.keymap are loaded always, sequentially reassigned key  bind‐
265       ings defined earlier.  User-defined keymap-file is searched on the fol‐
266       lowing algorithm (to the first one found):
267
268              1) command line option -K <keymap> or --keymap=<keymap>
269              2) Environment variable MC_KEYMAP
270              3) Parameter keymap in section  [Midnight-Commander]  of  config
271              file.
272              4) File ~/.config/mc/mc.keymap
273
274       Command  line option, environment variable and parameter in config file
275       may contain the absolute path to the keymap-file  (with  the  extension
276       .keymap  or  without  it).  Search of keymap-file will occur in (to the
277       first one found):
278
279              1) ~/.config/mc
280              2) /etc/mc/
281              3) /usr/share/mc/
282
283
284  Miscellaneous Keys
285       Here are some keys which don't fall into any of the other categories:
286
287       Enter  if there is some text in the command line (the one at the bottom
288              of  the  panels),  then that command is executed. If there is no
289              text in the command line then if the selection  bar  is  over  a
290              directory the Midnight Commander does a chdir(2) to the selected
291              directory and reloads the  information  on  the  panel;  if  the
292              selection is an executable file then it is executed. Finally, if
293              the extension of the selected  file  name  matches  one  of  the
294              extensions in the extensions file then the corresponding command
295              is executed.
296
297       C-l    repaint all the information in the Midnight Commander.
298
299       C-x c  run the Chmod command on a file or on the tagged files.
300
301       C-x o  run the Chown command on the  current  file  or  on  the  tagged
302              files.
303
304       C-x l  run the hard link command.
305
306       C-x s  run the absolute symbolic link command.
307
308       C-x v  run  the  relative symbolic link command. See the File Menu sec‐
309              tion for more information about symbolic links.
310
311       C-x i  set the other panel display mode to information.
312
313       C-x q  set the other panel display mode to quick view.
314
315       C-x !  execute the External panelize command.
316
317       C-x h  run the add directory to hotlist command.
318
319       Alt-!  executes the Filtered view command, described in the  view  com‐
320              mand.
321
322       Alt-?  executes the Find file command.
323
324       Alt-c  pops up the quick cd dialog.
325
326       C-o    when the program is being run in the Linux or FreeBSD console or
327              under an xterm, it will show you the output of the previous com‐
328              mand.   When  ran  on  the Linux console, the Midnight Commander
329              uses an external  program  (cons.saver)  to  handle  saving  and
330              restoring of information on the screen.
331
332       When  the subshell support is compiled in, you can type C-o at any time
333       and you will be taken back to the Midnight Commander  main  screen,  to
334       return  to  your application just type C-o.  If you have an application
335       suspended by using this trick, you won't be able to execute other  pro‐
336       grams  from  the  Midnight  Commander until you terminate the suspended
337       application.
338
339  Directory Panels
340       This section lists the keys which operate on the directory  panels.  If
341       you want to know how to change the appearance of the panels take a look
342       at the section on Left and Right Menus.
343
344       Tab, C-i
345              change the current panel. The old other panel  becomes  the  new
346              current  panel  and  the old current panel becomes the new other
347              panel. The selection bar moves from the old current panel to the
348              new current panel.
349
350       Insert, C-t
351              to  tag  files  you  may  use the Insert key (the kich1 terminfo
352              sequence).  To untag files, just retag a tagged file.
353
354       M-e    to change charset of panel you may use M-e (Alt-e).  Recoding is
355              made  from selected codepage into system codepage. To cancel the
356              recoding you may select "directory up" (..) in active panel.  To
357              cancel the charsets in all directories, select "No translation "
358              in the dialog of encodings.
359
360       Alt-g, Alt-r, Alt-j
361              used to select the top file in a panel, the middle file and  the
362              bottom one, respectively.
363
364       Alt-t  toggle  the  current  display  listing  to show the next display
365              listing mode.  With this it is possible  to  quickly  switch  to
366              brief listing, long listing, user defined listing mode, and back
367              to the default.
368
369       C-\ (control-backslash)
370              show the directory hotlist and change to the selected directory.
371
372       +  (plus)
373              this is used to select (tag) a group  of  files.   The  Midnight
374              Commander  will  prompt for a selection options. When Files only
375              checkbox is on, only files will be selected.  If Files  only  is
376              off,  as files as directories will be selected.  When Shell Pat‐
377              terns checkbox is on, the regular expression is  much  like  the
378              filename  globbing  in  the  shell  (* standing for zero or more
379              characters and ? standing for one character). If Shell  Patterns
380              is  off,  then  the tagging of files is done with normal regular
381              expressions (see ed (1)). When Case sensitive  checkbox  is  on,
382              the selection will be case sensitive characters.  If Case sensi‐
383              tive is off, the case will be ignored.
384
385       \ (backslash)
386              use the "\" key to unselect a group of files. This is the  oppo‐
387              site of the Plus key.
388
389       up-key, C-p
390              move the selection bar to the previous entry in the panel.
391
392       down-key, C-n
393              move the selection bar to the next entry in the panel.
394
395       home, a1, Alt-<
396              move the selection bar to the first entry in the panel.
397
398       end, c1, Alt->
399              move the selection bar to the last entry in the panel.
400
401       next-page, C-v
402              move the selection bar one page down.
403
404       prev-page, Alt-v
405              move the selection bar one page up.
406
407       Alt-o  If  the currently selected file is a directory, load that direc‐
408              tory on the other panel and moves  the  selection  to  the  next
409              file.  If  the  currently selected file is not a directory, load
410              the parent directory on the other panel and moves the  selection
411              to the next file.
412
413       Alt-i  make the current directory of the current panel also the current
414              directory of the other panel.  Put the other panel to the  list‐
415              ing  mode  if  needed.   If  the current panel is panelized, the
416              other panel doesn't become panelized.
417
418       C-PageUp, C-PageDown
419              only when supported by the terminal: change to ".." and  to  the
420              currently selected directory respectively.
421
422       Alt-y  moves  to  the  previous directory in the history, equivalent to
423              clicking the < with the mouse.
424
425       Alt-u  moves to the next directory in the history, equivalent to click‐
426              ing the > with the mouse.
427
428       Alt-Shift-h, Alt-H
429              displays the directory history, equivalent to depressing the 'v'
430              with the mouse.
431
432  Quick search
433       The Quick search mode allows you to perform fast file  search  in  file
434       panel.   Press C-s or Alt-s to start a filename search in the directory
435       listing.
436
437       When the search is active, the user input will be added to  the  search
438       string  instead  of the command line. If the Show mini-status option is
439       enabled the search string is shown on the mini-status line.  When  typ‐
440       ing,  the  selection  bar  will move to the next file starting with the
441       typed letters. The Backspace or DEL keys can be used to correct  typing
442       mistakes. If C-s is pressed again, the next match is searched for.
443
444       If  quick  search  is started with double pressing of C-s, the previous
445       quick search pattern will be used for current search.
446
447       Besides the filename characters, you can also use  wildcard  characters
448       '*' and '?'.
449
450  Shell Command Line
451       This section lists keys which are useful to avoid excessive typing when
452       entering shell commands.
453
454       Alt-Enter
455              copy the currently selected file name to the command line.
456
457       C-Enter
458              same a Alt-Enter.  May not work on remote systems and some  ter‐
459              minals.
460
461       C-Shift-Enter
462              copy  the  full  path name of the currently selected file to the
463              command line.  May not work on remote systems  and  some  termi‐
464              nals.
465
466       Alt-Tab
467              does the filename, command, variable, username and hostname com‐
468              pletion for you.
469
470       C-x t, C-x C-t
471              copy the tagged files (or if there  are  no  tagged  files,  the
472              selected  file)  of  the  current  panel (C-x t) or of the other
473              panel (C-x C-t) to the command line.
474
475       C-x p, C-x C-p
476              the first key sequence copies the current path name to the  com‐
477              mand line, and the second one copies the unselected panel's path
478              name to the command line.
479
480       C-q    the quote command can be used to insert characters that are oth‐
481              erwise  interpreted by the Midnight Commander (like the '+' sym‐
482              bol)
483
484       Alt-p, Alt-n
485              use these keys to browse  through  the  command  history.  Alt-p
486              takes you to the last entry, Alt-n takes you to the next one.
487
488       Alt-h  displays the history for the current input line.
489
490  General Movement Keys
491       The help viewer, the file viewer and the directory tree use common code
492       to handle moving. Therefore they accept exactly the same keys. Each  of
493       them also accepts some keys of its own.
494
495       Other  parts  of  the  Midnight Commander use some of the same movement
496       keys, so this section may be of use for those parts too.
497
498       Up, C-p
499              moves one line backward.
500
501       Down, C-n
502              moves one line forward.
503
504       Prev Page, Page Up, Alt-v
505              moves one page up.
506
507       Next Page, Page Down, C-v
508              moves one page down.
509
510       Home, A1
511              moves to the beginning.
512
513       End, C1
514              move to the end.
515
516       The help viewer and the file viewer accept the following keys in  addi‐
517       tion the to ones mentioned above:
518
519       b, C-b, C-h, Backspace, Delete
520              moves one page up.
521
522       Space bar
523              moves one page down.
524
525       u, d   moves one half of a page up or down.
526
527       g, G   moves to the beginning or to the end.
528
529  Input Line Keys
530       The  input  lines (they are used for the command line and for the query
531       dialogs in the program) accept these keys:
532
533       C-a    puts the cursor at the beginning of line.
534
535       C-e    puts the cursor at the end of the line.
536
537       C-b, move-left
538              move the cursor one position left.
539
540       C-f, move-right
541              move the cursor one position right.
542
543       Alt-f  moves one word forward.
544
545       Alt-b  moves one word backward.
546
547       C-h, Backspace
548              delete the previous character.
549
550       C-d, Delete
551              delete the character in the point (over the cursor).
552
553       C-@    sets the mark for cutting.
554
555       C-w    copies the text between the cursor and the mark to a kill buffer
556              and removes the text from the input line.
557
558       Alt-w  copies  the  text between the cursor and the mark to a kill buf‐
559              fer.
560
561       C-y    yanks back the contents of the kill buffer.
562
563       C-k    kills the text from the cursor to the end of the line.
564
565       Alt-p, Alt-n
566              Use these keys to browse  through  the  command  history.  Alt-p
567              takes you to the last entry, Alt-n takes you to the next one.
568
569       Alt-C-h, Alt-Backspace
570              delete one word backward.
571
572       Alt-Tab
573              does the filename, command, variable, username and hostname com‐
574              pletion for you.
575
576
578       The menu bar pops up when you press F9 or click the mouse  on  the  top
579       row  of  the screen. The menu bar has five menus: "Left", "File", "Com‐
580       mand", "Options" and "Right".
581
582       The Left and Right Menus allow you to modify the appearance of the left
583       and right directory panels.
584
585       The  File  Menu  lists  the  actions  you  can perform on the currently
586       selected file or the tagged files.
587
588       The Command Menu lists the actions which are more general and  bear  no
589       relation to the currently selected file or the tagged files.
590
591       The  Options  Menu  lists  the actions which allow you to customize the
592       Midnight Commander.
593
594  Left and Right (Above and Below) Menus
595       The outlook of the directory panels can be changed from  the  Left  and
596       Right  menus  (they are named Above and Below when the horizontal panel
597       split is chosen from the Layout options dialog).
598
599    Listing Mode...
600       The listing mode view is used to display a listing of files, there  are
601       four  different  listing  modes  available: Full, Brief, Long and User.
602       The full directory view shows the file name, the size of the  file  and
603       the modification time.
604
605       The  brief view shows only the file name and it has two columns (there‐
606       fore showing twice as many files as other views). The long view is sim‐
607       ilar  to  the  output  of  ls -l command. The long view takes the whole
608       screen width.
609
610       If you choose the "User" display format, then you have to  specify  the
611       display format.
612
613       The  user  display format must start with a panel size specifier.  This
614       may be "half" or "full", and they specify a half  screen  panel  and  a
615       full screen panel respectively.
616
617       After  the  panel  size,  you  may  specify the two columns mode on the
618       panel, this is done by adding the number "2" to the user format string.
619
620       After this you add the name of the fields with an optional size  speci‐
621       fier.  This are the available fields you may display:
622
623       name   displays the file name.
624
625       size   displays the file size.
626
627       bsize  is  an alternative form of the size format. It displays the size
628              of the files and  for  directories  it  just  shows  SUB-DIR  or
629              UP--DIR.
630
631       type   displays  a  one  character  wide type field.  This character is
632              similar to what is displayed by ls with the -F flag - * for exe‐
633              cutable  files, / for directories, @ for links, = for sockets, -
634              for character devices, + for block devices, | for pipes,  ~  for
635              symbolic  links  to directories and !  for stale symlinks (links
636              that point nowhere).
637
638       mark   an asterisk if the file is tagged, a space if it's not.
639
640       mtime  file's last modification time.
641
642       atime  file's last access time.
643
644       ctime  file's status change time.
645
646       perm   a string representing the current permission bits of the file.
647
648       mode   an octal value with the current permission bits of the file.
649
650       nlink  the number of links to the file.
651
652       ngid   the GID (numeric).
653
654       nuid   the UID (numeric).
655
656       owner  the owner of the file.
657
658       group  the group of the file.
659
660       inode  the inode of the file.
661
662       Also you can use following keywords to define the panel layout:
663
664       space  a space in the display format.
665
666       |      add a vertical line to the display format.
667
668       To force one field to a fixed size (a size specifier), you just  add  :
669       followed  by  the  number of characters you want the field to have.  If
670       the number is followed by the symbol +, then  the  size  specifies  the
671       minimal  field size - if the program finds out that there is more space
672       on the screen, it will then expand that field.
673
674       For example, the Full display corresponds to this format:
675
676       half type name | size | mtime
677
678       And the Long display corresponds to this format:
679
680       full perm space nlink space owner space group space  size  space  mtime
681       space name
682
683       This is a nice user display format:
684
685       half name | size:7 | type mode:3
686
687       Panels may also be set to the following modes:
688
689       Info   The  info  view  display  information  related  to the currently
690              selected file and if possible information about the current file
691              system.
692
693       Tree   The  tree  view  is quite similar to the directory tree feature.
694              See the section about it for more information.
695
696       Quick View
697              In this mode, the panel will switch to  a  reduced  viewer  that
698              displays  the  contents  of  the currently selected file, if you
699              select the panel (with the tab key or the mouse), you will  have
700              access to the usual viewer commands.
701
702    Sort Order...
703       The  eight sort orders are by name, by extension, by modification time,
704       by access time, and by inode information modification time, by size, by
705       inode  and  unsorted.   In the Sort order dialog box you can choose the
706       sort order and you may also specify if you  want  to  sort  in  reverse
707       order by checking the reverse box.
708
709       By  default directories are sorted before files but this can be changed
710       from the Panel options menu (option Mix all files).
711
712    Filter...
713       The filter command allows you to specify a shell pattern  (for  example
714       *.tar.gz)  which  the  files  must match to be shown. Regardless of the
715       filter pattern, the directories and the links to directories are always
716       shown in the directory panel.
717
718    Reread
719       The  reread  command  reload  the list of files in the directory. It is
720       useful if other processes have created or removed files.
721
722  File Menu
723       The Midnight Commander uses the F1 - F10 keys as keyboard shortcuts for
724       commands  appearing  in  the  file  menu.  The escape sequences for the
725       function keys are terminfo capabilities kf1 trough kf10.  On  terminals
726       without function key support, you can achieve the same functionality by
727       pressing the ESC key and then a number in the range 1 through 9  and  0
728       (corresponding to F1 to F9 and F10 respectively).
729
730       The  File menu has the following commands (keyboard shortcuts in paren‐
731       theses):
732
733       Help (F1)
734
735       Invokes the built-in hypertext help viewer. Inside the help viewer, you
736       can use the Tab key to select the next link and the Enter key to follow
737       that link. The keys Space and Backspace are used to  move  forward  and
738       backward  in  a  help  page.  Press  F1  again  to get the full list of
739       accepted keys.
740
741       Menu (F2)
742
743       Invoke the user menu.  The user menu provides an easy  way  to  provide
744       users with a menu and add extra features to the Midnight Commander.
745
746       View (F3, F13)
747
748       View  the currently selected file. By default this invokes the Internal
749       File Viewer but if the option "Use internal view" is off, it invokes an
750       external  file viewer specified by the VIEWER environment variable.  If
751       VIEWER is undefined, the PAGER environment variable is tried.  If PAGER
752       is  also  undefined,  the  "view"  command  is invoked.  If you use F13
753       instead, the viewer will be invoked without  doing  any  formatting  or
754       preprocessing to the file.
755
756       Filtered View (Alt-!)
757
758       This  command  prompts  for  a  command and its arguments (the argument
759       defaults to the currently selected file name),  the  output  from  such
760       command is shown in the internal file viewer.
761
762       Edit (F4, F14)
763
764       Press  F4  to  edit  the  highlighted file.  Press F14 (usually F14) to
765       start the editor with a new, empty file.  Currently they invoke the  vi
766       editor,  or the editor specified in the EDITOR environment variable, or
767       the Internal File Editor if the use_internal_edit option is on.
768
769       Copy (F5, F15)
770
771       Press F5 to pop up an input dialog to copy the currently selected  file
772       (or  the  tagged  files,  if  there is at least one file tagged) to the
773       directory/filename you specify in the  input  dialog.  The  destination
774       defaults to the directory in the non-selected panel. Space for destina‐
775       tion file may be preallocated relative to  preallocate_space  configure
776       option.   During  this  process,  you can press C-c or ESC to abort the
777       operation.  For details about source mask (which will be usually either
778       *  or ^\(.*\)$ depending on setting of Use shell patterns) and possible
779       wildcards in the destination see Mask copy/rename.
780
781       F15 (usually F15) is similar, but defaults  to  the  directory  in  the
782       selected  panel. It always operates on the selected file, regardless of
783       any tagged files.
784
785       On some systems, it is possible to do the copy  in  the  background  by
786       clicking  on  the  background  button  (or pressing Alt-b in the dialog
787       box).  The Background Jobs is used to control the background process.
788
789       Link (C-x l)
790
791       Create a hard link to the current file.
792
793       Absolute symlink (C-x s)
794
795       Create a absolute symbolic link to the current file.
796
797       Relative symLink (C-x v)
798
799       Create a relative symbolic link to the current file.
800
801       To those of you who don't know what links are: creating  a  link  to  a
802       file  is  a bit like copying the file, but both the source filename and
803       the destination filename represent the same file image. For example, if
804       you  edit  one of these files, all changes you make will appear in both
805       files. Some people call links aliases or shortcuts.
806
807       A hard link appears as a real file. After making it, there is no way of
808       telling  which one is the original and which is the link. If you delete
809       either one of them the other one is still intact. It is very  difficult
810       to  notice that the files represent the same image. Use hard links when
811       you don't even want to know.
812
813       A symbolic link is a reference to the name of the original file. If the
814       original file is deleted the symbolic link is useless. It is quite easy
815       to notice that the files represent the same image. The Midnight Comman‐
816       der  shows  an  "@"-sign  in front of the file name if it is a symbolic
817       link to somewhere (except to directory, where it shows  a  tilde  (~)).
818       The original file which the link points to is shown on mini-status line
819       if the Show mini-status option is enabled. Use symbolic links when  you
820       want to avoid the confusion that can be caused by hard links.
821
822       When  you  press  "C-x s" Midnight Commander will automatically fill in
823       the complete path+filename of the original file and suggest a name  for
824       the link.  You can change either one.
825
826       Sometimes you may want to change the absolute path of the original into
827       a relative path. An absolute path starts from the root directory:
828
829       /home/frodo/mc/mc -> /home/frodo/new/mc
830
831       A relative link describes the original file's  location  starting  from
832       the location of the link itself:
833
834       /home/frodo/mc/mc -> ../new/mc
835
836       You can force Midnight Commander to suggest a relative path by pressing
837       "C-x v" instead of "C-x s".
838
839       Rename/Move (F6, F16)
840
841       Press F6 to pop up an input dialog to copy the currently selected  file
842       (or  the  tagged  files,  if  there is at least one file tagged) to the
843       directory/filename you specify in the input  dialog.   The  destination
844       defaults  to  the directory in the non-selected panel. For more details
845       look at Copy (F5) operation above, most of the things are  quite  simi‐
846       lar.
847
848       F16  (usually  F16)  is  similar,  but defaults to the directory in the
849       selected panel. It always operates on the selected file, regardless  of
850       any tagged files.
851
852       On  some  systems,  it  is possible to do the copy in the background by
853       clicking on the background button (or  pressing  Alt-b  in  the  dialog
854       box).  The Background Jobs is used to control the background process.
855
856       Mkdir (F7)
857
858       Pop up an input dialog and creates the directory specified.
859
860       Delete (F8)
861
862       Delete the currently selected file or the tagged files in the currently
863       selected panel. During the process, you can press C-c or ESC  to  abort
864       the operation.
865
866       Quick cd (Alt-c) Use the quick cd command if you have full command line
867       and want to cd somewhere.
868
869       Select group (+)
870
871       This is used to select (tag) a group of files. The  Midnight  Commander
872       will  prompt  for  a selection options. When Files only checkbox is on,
873       only files will be selected.  If Files only is off, as files as  direc‐
874       tories will be selected.  When Shell Patterns checkbox is on, the regu‐
875       lar expression is much like the  filename  globbing  in  the  shell  (*
876       standing  for  zero  or more characters and ?  standing for one charac‐
877       ter). If Shell Patterns is off, then the tagging of files is done  with
878       normal  regular  expressions (see ed (1)). When Case sensitive checkbox
879       is on, the selection will be case sensitive characters.  If Case sensi‐
880       tive is off, the case will be ignored.
881
882       Unselect group (\)
883
884       Used  to  unselect a group of files. This is the opposite of the Select
885       group command.
886
887       Quit (F10, Shift-F10)
888
889       Terminate the Midnight Commander.  Shift-F10 is used when you  want  to
890       quit  and you are using the shell wrapper.  Shift-F10 will not take you
891       to the last directory you visited with the Midnight Commander,  instead
892       it will stay at the directory where you started the Midnight Commander.
893
894    Quick cd
895       This  command  is useful if you have a full command line and want to cd
896       somewhere without having to yank and paste the command line. This  com‐
897       mand pops up a small dialog, where you enter everything you would enter
898       after cd on the command line and then you press  enter.  This  features
899       all the things that are already in the internal cd command.
900
901  Command Menu
902       The Directory tree command shows a tree figure of the directories.
903
904       The "Find file" command allows you to search for a specific file.
905
906       The  "Swap panels" command swaps the contents of the two directory pan‐
907       els.
908
909       The "Switch panels on/off" command shows the output of the  last  shell
910       command.  This works only on xterm and on Linux and FreeBSD console.
911
912       The  "Compare  directories"  command compares the directory panels with
913       each other. You can then use the Copy (F5) command to make  the  panels
914       identical.  There  are three compare methods. The quick method compares
915       only file size  and  file  date.  The  thorough  method  makes  a  full
916       byte-by-byte  compare.  The  thorough  method  is  not available if the
917       machine does not support the mmap(2) system call.  The  size-only  com‐
918       pare  method  just  compares the file sizes and does not check the con‐
919       tents or the date times, it just checks the file size.
920
921       The "External panelize" allows you to execute an external program,  and
922       make the output of that program the contents of the current panel.
923
924       The  "Command  history"  command  shows  a  list of typed commands. The
925       selected command is copied to the command line. The command history can
926       also be accessed by typing Alt-p or Alt-n.
927
928       The "Directory hotlist" command makes changing of the current directory
929       to often used directories faster.
930
931       The "Screen list" command shows a dialog window with the list  of  cur‐
932       rently running internal editors, viewers and other MC modules that sup‐
933       port this mode.
934
935       The "Edit extension file" command allows you  to  specify  programs  to
936       executed  when  you  try to execute, view, edit and do a bunch of other
937       thing on files with certain extensions (filename endings).
938
939       The "Edit menu file" command may be used  for  editing  the  user  menu
940       (which appears by pressing F2).
941
942    Directory Tree
943       The  Directory Tree command shows a tree figure of the directories. You
944       can select a directory from the figure and the Midnight Commander  will
945       change to that directory.
946
947       There  are two ways to invoke the tree. The real directory tree command
948       is available from Commands menu. The other way is to select  tree  view
949       from the Left or Right menu.
950
951       To  get rid of long delays the Midnight Commander creates the tree fig‐
952       ure by scanning only a small subset of  all  the  directories.  If  the
953       directory  which  you want to see is missing, move to its parent direc‐
954       tory and press C-r (or F2).
955
956       You can use the following keys:
957
958       General movement keys are accepted.
959
960       Enter.  In the directory tree, exits the directory tree and changes  to
961       this  directory in the current panel. In the tree view, changes to this
962       directory in the other panel and stays in tree view mode in the current
963       panel.
964
965       C-r, F2 (Rescan).  Rescan this directory. Use this when the tree figure
966       is out of date: it is missing subdirectories or shows some  subdirecto‐
967       ries which don't exist any more.
968
969       F3  (Forget).   Delete this directory from the tree figure. Use this to
970       remove clutter from the figure. If you want the directory back  to  the
971       tree figure press F2 in its parent directory.
972
973       F4  (Static/Dynamic).   Toggle  between  the  dynamic  navigation  mode
974       (default) and the static navigation mode.
975
976       In the static navigation mode you can use  the  Up  and  Down  keys  to
977       select a directory. All known directories are shown.
978
979       In  the  dynamic  navigation  mode  you can use the Up and Down keys to
980       select a sibling directory, the Left key to move to the  parent  direc‐
981       tory,  and the Right key to move to a child directory. Only the parent,
982       sibling and children directories are shown, others are  left  out.  The
983       tree figure changes dynamically as you traverse.
984
985       F5 (Copy).  Copy the directory.
986
987       F6 (RenMov).  Move the directory.
988
989       F7 (Mkdir).  Make a new directory below this directory.
990
991       F8 (Delete).  Delete this directory from the file system.
992
993       C-s,  Alt-s.   Search the next directory matching the search string. If
994       there is no such directory these keys will move one line down.
995
996       C-h, Backspace.  Delete the last character of the search string.
997
998       Any other character.  Add the character to the search string  and  move
999       to  the  next directory which starts with these characters. In the tree
1000       view you must first activate the  search  mode  by  pressing  C-s.  The
1001       search string is shown in the mini status line.
1002
1003       The  following  actions  are available only in the directory tree. They
1004       aren't supported in the tree view.
1005
1006       F1 (Help).  Invoke the help viewer and show this section.
1007
1008       Esc, F10.  Exit the directory tree. Do not change the directory.
1009
1010       The mouse is supported. A double-click behaves like Enter. See also the
1011       section on mouse support.
1012
1013    Find File
1014       The Find File feature first asks for the start directory for the search
1015       and the filename to be searched for. By pressing the  Tree  button  you
1016       can select the start directory from the directory tree figure.
1017
1018       Option form whole words. Like grep -w.
1019
1020       You  can start the search by pressing the OK button.  During the search
1021       you can stop from the Stop button and continue from the Start button.
1022
1023       You can browse the filelist with the up and down arrow keys. The  Chdir
1024       button will change to the directory of the currently selected file. The
1025       Again button will ask for the parameters for a  new  search.  The  Quit
1026       button  quits  the search operation. The Panelize button will place the
1027       found files to the current directory panel so that  you  can  do  addi‐
1028       tional  operations  on them (view, copy, move, delete and so on). After
1029       panelizing you can press C-r to return to the normal file listing.
1030
1031       The 'Enable ignore directories' checkbox and input field below it allow
1032       to set up the list of directories that should be skip during the search
1033       files (for example, you may want to avoid searches on a CD-ROM or on  a
1034       NFS directory that is mounted across a slow link). List components must
1035       be separated with a colon, here is an example:
1036
1037       /cdrom:/nfs/wuarchive:/afs
1038
1039       Relative paths are supported also. The following example shows  how  to
1040       skip special directories of version control systems:
1041       /cdrom:/nfs/wuarchive:/afs:.svn:.git:CVS
1042
1043       Attention:  input  field  can contain a dot (.), this means the current
1044       absolute path.
1045
1046       You may consider using the External panelize command  for  some  opera‐
1047       tions. Find file command is for simple queries only, while using Exter‐
1048       nal panelize you can do as mysterious searches as you would like.
1049
1050    External panelize
1051       The External panelize allows you to execute an  external  program,  and
1052       make the output of that program the contents of the current panel.
1053
1054       For  example,  if  you  want to manipulate in one of the panels all the
1055       symbolic links in the current directory, you can use external paneliza‐
1056       tion to run the following command:
1057
1058       find . -type l -print
1059
1060       Upon  command  completion,  the directory contents of the panel will no
1061       longer be the directory listing of the current directory, but  all  the
1062       files that are symbolic links.
1063
1064       If you want to panelize all of the files that have been downloaded from
1065       your FTP server, you can use this awk command to extract the file  name
1066       from the transfer log files:
1067
1068       awk '$9 ~! /incoming/ { print $9 }' < /var/log/xferlog
1069
1070       You  may  want to save often used panelize commands under a descriptive
1071       name, so that you can recall them quickly. You do this  by  typing  the
1072       command on the input line and pressing Add new button. Then you enter a
1073       name under which you want the command to be saved. Next time, you  just
1074       choose that command from the list and do not have to type it again.
1075
1076    Hotlist
1077       The  Directory  hotlist  command shows the labels of the directories in
1078       the directory hotlist.  The  Midnight  Commander  will  change  to  the
1079       directory  corresponding  to the selected label.  From the hotlist dia‐
1080       log, you can remove already created label/directory pairs and  add  new
1081       ones.   To  add new directories quickly, you can use the Add to hotlist
1082       command (C-x h), which adds the current directory  into  the  directory
1083       hotlist, asking just for the label for the directory.
1084
1085       This  makes cd to often used directories faster. You may consider using
1086       the CDPATH variable as described in internal cd command description.
1087
1088    Extension File Edit
1089       This will invoke your editor on the file ~/.config/mc/mc.ext.  The for‐
1090       mat of this file following:
1091
1092       All lines starting with # or empty lines are thrown away.
1093
1094       Lines starting in the first column should have following format:
1095
1096       keyword/expr, i.e. everything after the slash until new line is expr.
1097
1098       keyword can be:
1099
1100       shell  - expr is an extension (no wildcards).  File matches it its name
1101              ends with expr.  Example: shell/.tar matches *.tar.
1102
1103       regex  - expr is a  regular  expression.   File  matches  if  its  name
1104              matches the regular expression.
1105
1106       directory
1107              -  expr is a regular expression.  File matches if it is a direc‐
1108              tory and its name matches the regular expression.
1109
1110       type   - expr is a regular expression.  File matches if the  output  of
1111              file  %f  without  the  initial "filename:" part matches regular
1112              expression expr.
1113
1114       default
1115              - matches any file.  expr is ignored.
1116
1117       include
1118              - denotes a common section.  expr is the name of the section.
1119
1120       Other lines should start with a space or tab and should be of the  for‐
1121       mat:  keyword=command  (with  no spaces around =), where keyword should
1122       be: Open (invoked on Enter or double click), View (F3),  Edit  (F4)  or
1123       Include  (to  add  rules  from  the  common  section).   command is any
1124       one-line shell command, with the simple macro substitution.
1125
1126       Rules are matched from top to bottom, thus the order is important.   If
1127       the  appropriate  action  is  missing, search continues as if this rule
1128       didn't match (i.e. if a file matches the first  and  second  entry  and
1129       View  action  is missing in the first one, then on pressing F3 the View
1130       action from the second entry will be used).  default should  match  all
1131       the actions.
1132
1133    Background Jobs
1134       This  lets  you  control the state of any background Midnight Commander
1135       process (only copy and move files operations can be done in  the  back‐
1136       ground).  You can stop, restart and kill a background job from here.
1137
1138    Menu File Edit
1139       The user menu is a menu of useful actions that can be customized by the
1140       user. When you access the user menu, the file .mc.menu from the current
1141       directory is used if it exists, but only if it is owned by user or root
1142       and is not world-writable.  If no such file found, ~/.config/mc/menu is
1143       tried  in  the  same way, and otherwise mc uses the default system-wide
1144       menu /usr/share/mc/mc.menu.
1145
1146       The format of the menu file is very simple. Lines that start with  any‐
1147       thing but space or tab are considered entries for the menu (in order to
1148       be able to use it like a hot key, the first character should be a  let‐
1149       ter).  All  the lines that start with a space or a tab are the commands
1150       that will be executed when the entry is selected.
1151
1152       When an option is selected all the command  lines  of  the  option  are
1153       copied  to  a  temporary  file  in  the  temporary  directory  (usually
1154       /usr/tmp) and then that file is executed. This allows the user  to  put
1155       normal  shell  constructs  in the menus. Also simple macro substitution
1156       takes place before executing the menu code. For more  information,  see
1157       macro substitution.
1158
1159       Here is a sample mc.menu file:
1160
1161       A    Dump the currently selected file
1162            od -c %f
1163
1164       B    Edit a bug report and send it to root
1165            I=`mktemp ${MC_TMPDIR:-/tmp}/mail.XXXXXX` || exit 1
1166            vi $I
1167            mail -s "Midnight Commander bug" root < $I
1168            rm -f $I
1169
1170       M    Read mail
1171            emacs -f rmail
1172
1173       N    Read Usenet news
1174            emacs -f gnus
1175
1176       H    Call the info hypertext browser
1177            info
1178
1179       J    Copy current directory to other panel recursively
1180            tar cf - . | (cd %D && tar xvpf -)
1181
1182       K    Make a release of the current subdirectory
1183            echo -n "Name of distribution file: "
1184            read tar
1185            ln -s %d `dirname %d`/$tar
1186            cd ..
1187            tar cvhf ${tar}.tar $tar
1188
1189       = f *.tar.gz | f *.tgz & t n
1190       X       Extract the contents of a compressed tar file
1191            tar xzvf %f
1192
1193       Default Conditions
1194
1195       Each  menu  entry  may  be  preceded by a condition. The condition must
1196       start from the first column with a '=' character. If the  condition  is
1197       true, the menu entry will be the default entry.
1198
1199       Condition syntax:   = <sub-cond>
1200         or:               = <sub-cond> | <sub-cond> ...
1201         or:               = <sub-cond> & <sub-cond> ...
1202
1203       Sub-condition is one of following:
1204
1205         y <pattern>       syntax of current file matching pattern?
1206                      (for edit menu only)
1207         f <pattern>       current file matching pattern?
1208         F <pattern>       other file matching pattern?
1209         d <pattern>       current directory matching pattern?
1210         D <pattern>       other directory matching pattern?
1211         t <type>          current file of type?
1212         T <type>          other file of type?
1213         x <filename>      is it executable filename?
1214         ! <sub-cond>      negate the result of sub-condition
1215
1216       Pattern is a normal shell pattern or a regular expression, according to
1217       the shell patterns option. You can override the  global  value  of  the
1218       shell  patterns  option by writing "shell_patterns=x" on the first line
1219       of the menu file (where "x" is either 0 or 1).
1220
1221       Type is one or more of the following characters:
1222
1223         n  not a directory
1224         r  regular file
1225         d  directory
1226         l  link
1227         c  character device
1228         b  block device
1229         f  FIFO (pipe)
1230         s  socket
1231         x  executable file
1232         t  tagged
1233
1234       For example 'rlf' means either regular file, link or fifo. The 't' type
1235       is  a  little special because it acts on the panel instead of the file.
1236       The condition '=t t' is true if there are tagged files in  the  current
1237       panel and false if not.
1238
1239       If  the condition starts with '=?' instead of '=' a debug trace will be
1240       shown whenever the value of the condition is calculated.
1241
1242       The conditions are calculated from left to right. This means
1243            = f *.tar.gz | f *.tgz & t n
1244       is calculated as
1245            ( (f *.tar.gz) | (f *.tgz) ) & (t n)
1246
1247       Here is a sample of the use of conditions:
1248
1249       = f *.tar.gz | f *.tgz & t n
1250       L    List the contents of a compressed tar-archive
1251            gzip -cd %f | tar xvf -
1252
1253       Addition Conditions
1254
1255       If the condition begins with '+' (or '+?') instead of '=' (or '=?')  it
1256       is  an addition condition. If the condition is true the menu entry will
1257       be included in the menu. If the condition is false the menu entry  will
1258       not be included in the menu.
1259
1260       You  can  combine default and addition conditions by starting condition
1261       with '+=' or '=+' (or '+=?' or '=+?' if you want debug trace).  If  you
1262       want  to  use  two different conditions, one for adding and another for
1263       defaulting, you can precede a menu entry with two condition lines,  one
1264       starting with '+' and another starting with '='.
1265
1266       Comments  are started with '#'. The additional comment lines must start
1267       with '#', space or tab.
1268
1269  Options Menu
1270       The Midnight Commander has some options that may be toggled on and  off
1271       in  several  dialogs  which  are accessible from this menu. Options are
1272       enabled if they have an asterisk or "x" in front of them.
1273
1274       The Configuration command pops up a dialog from which  you  can  change
1275       most of settings of the Midnight Commander.
1276
1277       The  Layout  command pops up a dialog from which you specify a bunch of
1278       options how mc looks like on the screen.
1279
1280       The Panel options command pops up  a  dialog  from  which  you  specify
1281       options of file manager panels.
1282
1283       The  Confirmation command pops up a dialog from which you specify which
1284       actions you want to confirm.
1285
1286       The Display bits command pops up a dialog from  which  you  may  select
1287       which characters is your terminal able to display.
1288
1289       The  Learn  keys command pops up a dialog from which you test some keys
1290       which are not working on some terminals and you may fix them.
1291
1292       The Virtual FS command pops up a dialog from which you specify some VFS
1293       related options.
1294
1295       The  Save  setup  command saves the current settings of the Left, Right
1296       and Options menus. A small number of other settings is saved, too.
1297
1298    Configuration
1299       The options in this dialog are divided into several groups: "File oper‐
1300       ation options", "Esc key mode", "Pause after run" and "Other options".
1301
1302       File operation options
1303
1304       Verbose  operation.   This  toggles  whether  the file Copy, Rename and
1305       Delete operations are verbose (i.e., display  a  dialog  box  for  each
1306       operation).  If  you  have a slow terminal, you may wish to disable the
1307       verbose operation. It is automatically turned off if the speed of  your
1308       terminal is less than 9600 bps.
1309
1310       Compute totals.  If this option is enabled, the Midnight Commander com‐
1311       putes total byte sizes and total number of files  prior  to  any  Copy,
1312       Rename  and  Delete operations. This will provide you with a more accu‐
1313       rate progress bar at the expense of some  speed.  This  option  has  no
1314       effect, if Verbose operation is disabled.
1315
1316       Classic  progressbar.   If  this  option is enabled, the progressbar of
1317       Copy/Move/Delete operations is always grown form left to right. If dis‐
1318       abled,  the  growing  direction  of progressbar follows to direction of
1319       Copy/Move/Delete operation: from left  panel  to  right  one  and  vice
1320       versa. Enabled by default.
1321
1322       Mkdir  autoname  When you press F7 to create a new directory, the input
1323       line in popup dialog will be filled by name of current file  or  direc‐
1324       tory in active panel.  Disabled by default.
1325
1326       Preallocate space Preallocate space for whole target file, if possible,
1327       before copy operation.  Disabled by default.
1328
1329       Esc key mode.
1330
1331       By default the Midnight Commander treats the ESC key as a  key  prefix.
1332       Therefore,  you should press Esc code twice to exit a dialog. But there
1333       is a possibility to use a single press of ESC key for that action.
1334
1335       Single press.  By default this option is disabled. If you'll enable it,
1336       the  ESC  key  will  act  as a prefix key for set up time interval (see
1337       Timeout option below), and if no extra keys have arrived, then the  ESC
1338       key is interpreted as a cancel key (ESC ESC).
1339
1340       Timeout.  This options is used to setup the time interval (in microsec‐
1341       onds) for single press of ESC key. By default,  this  inrerval  is  one
1342       second  (1000000  microseconds).  Also  the timeout can be set via KEY‐
1343       BOARD_KEY_TIMEOUT_US environment variable (also in microseconds), which
1344       has higher priority than Timeout option value.
1345
1346       Pause after run
1347
1348       After  executing  your  commands,  the Midnight Commander can pause, so
1349       that you can examine the output of the command.  There are three possi‐
1350       ble settings for this variable:
1351
1352       Never.   Means  that you do not want to see the output of your command.
1353       If you are using the Linux or FreeBSD console or an xterm, you will  be
1354       able to see the output of the command by typing C-o.
1355
1356       Ondumbterminals.   You will get the pause message on terminals that are
1357       not capable of showing the output of the  last  command  executed  (any
1358       terminal that is not an xterm or the Linux console).
1359
1360       Always.  The program will pause after executing all of your commands.
1361
1362       Other options
1363
1364       Use internal editor.  If this option is enabled, the built-in file edi‐
1365       tor is used to edit files. If the option is disabled, the editor speci‐
1366       fied in the EDITOR environment variable is used.  If no editor is spec‐
1367       ified, vi is used.  See the section on the internal file editor.
1368
1369       Use internal viewer.  If this option  is  enabled,  the  built-in  file
1370       viewer  is  used  to  view  files. If the option is disabled, the pager
1371       specified in the PAGER environment variable is used.  If  no  pager  is
1372       specified,  the  view command is used.  See the section on the internal
1373       file viewer.
1374
1375       Auto menus.  If this option is enabled, the user menu will  be  invoked
1376       at startup.  Useful for building menus for non-unixers.
1377
1378       Drop down menus.  When this option is enabled, the pull down menus will
1379       be activated as soon as you press the F9 key. Otherwise, you will  only
1380       get  the menu title, and you will have to activate the menu either with
1381       the arrow keys or with the hotkeys. It is recommended if you are  using
1382       hotkeys.
1383
1384       Shell  Patterns.   By  default the Select, Unselect and Filter commands
1385       will use shell-like regular expressions. The following conversions  are
1386       performed  to  achieve  this: the '*' is replaced by '.*' (zero or more
1387       characters); the '?'  is replaced by '.' (exactly  one  character)  and
1388       '.'  by  the  literal  dot. If the option is disabled, then the regular
1389       expressions are the ones described in ed(1).
1390
1391       Complete: show all.  By default the Midnight Commander pops up all pos‐
1392       sible  completions  if  the completion is ambiguous only when you press
1393       Alt-Tab for the second time.  For the first time, it just completes  as
1394       much  as  possible  and  beeps  in  the case of ambiguity.  Enable this
1395       option if you want to see all possible completions even after  pressing
1396       Alt-Tab the first time.
1397
1398       Rotating dash.  If this option is enabled, the Midnight Commander shows
1399       a rotating dash in the upper right corner as a work in progress indica‐
1400       tor.
1401
1402       Cd  follows  links.  This option, if set, causes the Midnight Commander
1403       to follow the logical chain of directories when changing current direc‐
1404       tory either in the panels, or using the cd command. This is the default
1405       behavior of bash. When unset, the Midnight Commander follows  the  real
1406       directory  structure, so cd .. if you've entered that directory through
1407       a link will move you to the current directory's real parent and not  to
1408       the directory where the link was present.
1409
1410       Safe  delete.   If this option is enabled, deleting files and directory
1411       hotlist entries unintentionally becomes more  difficult.   The  default
1412       selection  in  the confirmation dialogs for deletion changes from "Yes"
1413       to "No".  This option is disabled by default.
1414
1415       Auto save setup.  If this option is enabled, when you exit the Midnight
1416       Commander  the configurable options of the Midnight Commander are saved
1417       in the ~/.config/mc/ini file.
1418
1419    Layout
1420       The layout dialog gives you a possibility to change the general  layout
1421       of  screen. The options in this dialog are divided into several groups:
1422       "Panel split", "Console output" and "Other options".
1423
1424       Panel split
1425
1426       The rest of the screen area is used for the two directory  panels.  You
1427       can specify whether the area is split to the panels in Vertical
1428        or  Horizontal  direction.  Panel  layout  can  be changed using Alt-,
1429       (Alt-comma) shortcut.
1430
1431       Equal split.  By default, panels have equal sizes.  Using  this  option
1432       you can specify an unequal split.
1433
1434       Console output
1435
1436       On  the  Linux  or  FreeBSD  console you can specify how many lines are
1437       shown in the output window. This option is available if  Midnight  Com‐
1438       mander runs on native console only.
1439
1440       Other options
1441
1442       Menu  bar  visible.   If  enabled,  main  menu of Midnight Commander is
1443       always visible on the top  row  of  screen  above  panels.  Enabled  by
1444       default.
1445
1446       Command  prompt.   If  enabled,  command  line  is avalable. Enabled by
1447       default.
1448
1449       Keybar visible.  If enabled, 10 lables associated with F1-F10 keys  are
1450       located at the bottom row of screen. Enabled by default.
1451
1452       Hintbar visible.  If enabled, the one-line hints are visible below pan‐
1453       els. Enabled by default.
1454
1455       XTerm window title.  When run in a terminal emulator for X11,  Midnight
1456       Commander  sets the terminal window title to the current working direc‐
1457       tory and updates it when necessary.  If your terminal emulator is  bro‐
1458       ken  and you see some incorrect output on startup and directory change,
1459       turn off this option.  Enabled by default.
1460
1461       Show free space.  If enabled, free space and  total  space  of  current
1462       file system is shown at the bottom frame of panel. Enabled by default.
1463
1464    Panel options
1465       Main panel options
1466
1467       Show mini-status.  If enabled, one line of status information about the
1468       currently selected item is shown at the bottom of the  panels.  Enabled
1469       by default.
1470
1471       Use  SI size units.  If this option is enabled, Midnight Commander will
1472       use SI units (powers of 1000) when displaying any byte sizes. The  suf‐
1473       fixes  (k,  m ...) are shown in lowercase.  If disabled (default), Mid‐
1474       night Commander will use binary units (powers of 1024) and the suffixes
1475       are shown in upper case (K, M ...)
1476
1477       Mix  all  files.   If this option is enabled, all files and directories
1478       are shown mixed together.  If the option is desabled (default),  direc‐
1479       tories  (and  links  to  directories) are shown at the beginning of the
1480       listing, and other files below.
1481
1482       Show backup files.  If enabled, the Midnight Commander will show  files
1483       ending  with  a  tilde.   Otherwise, they won't be shown (like GNU's ls
1484       option -B). Enabled by default.
1485
1486       Show hidden files.  If enabled, the Midnight Commander  will  show  all
1487       files that start with a dot (like ls -a). Disabled by default.
1488
1489       Fast directory reload.  If this option is enabled, the Midnight Comman‐
1490       der will use a trick  to  determine  if  the  directory  contents  have
1491       changed.   The  trick  is to reload the directory only if the i-node of
1492       the directory has changed; this means that  reloads  only  happen  when
1493       files are created or deleted.  If what changes is the i-node for a file
1494       in the directory (file size changes, mode or owner  changes,  etc)  the
1495       display is not updated.  In these cases, if you have the option on, you
1496       have to rescan the directory manually (with C-r). Disabled by default.
1497
1498       Mark moves down.  If enabled, the selection bar will move down when you
1499       mark a file (with Insert key). Enabled by default.
1500
1501       Reverse  files  only.  Allow revert selection of files only. Enabled by
1502       default.  If enabled, the reverse selection is applied to  files  only,
1503       not to directories.  The selection of directories is untouched. If off,
1504       the reverse selection is applied to files as well to  directories:  all
1505       unselected items become selected, and vice versa.
1506
1507       Simple  swap.   If  both panels contain file listing, simple swap means
1508       that panels exchange its screen positions: left panel become right one,
1509       and  vice  versa.  If  this  option  is  unchecked, file listing panels
1510       exchange its content keeping listing format and sort options. Unchecked
1511       by default.
1512
1513       Auto  save  panels setup.  If this option is enabled, when you exit the
1514       Midnight Commander the current settings of  panels  are  saved  in  the
1515       ~/.config/mc/panels.ini file.  Disabled by default.
1516
1517       Navigation
1518
1519       Lynx-like  motion.   If  this option is enabled, you may use the arrows
1520       keys to automatically chdir if the current selection is a  subdirectory
1521       and the shell command line is empty. By default, this setting is off.
1522
1523       Page  scrolling.   If  set (the default), panel will scroll by half the
1524       display when the cursor reaches the end or the beginning of the  panel,
1525       otherwise it will just scroll a file at a time.
1526
1527       Mouse page scrolling.  Controls whenever scrolling with the mouse wheel
1528       is done by pages or line by line on the panels.
1529
1530       File highlight
1531
1532       You can specify whether permissions and  file  types  should  be  high‐
1533       lighted  with  distinctive  Colors.   If the permission highlighting is
1534       enabled, the parts of the perm and mode display fields which  apply  to
1535       the  user  running  Midnight  Commander  are highlighted with the color
1536       defined by the selected keyword.  If  the  file  type  highlighting  is
1537       enabled,  file  names  are  colored  according  to  rules  described in
1538       /etc/mc/filehighlight.ini file. See Filenames Highlight for more info.
1539
1540       Quick search
1541
1542       You can specify how the Quick search mode should  work:  case  insensi‐
1543       tively,  case  sensitively  or be matched to the panel sort order: case
1544       sensitive or not.
1545
1546    Confirmation
1547       In this dialog you configure the confirmation options  for  file  dele‐
1548       tion, overwriting files, execution by pressing enter, quitting the pro‐
1549       gram, directory hotlist entries deletion and history cleanup.
1550        and.
1551
1552    Display bits
1553       This is used to configure  the  range  of  visible  characters  on  the
1554       screen.   This  setting  may be 7-bits if your terminal/curses supports
1555       only seven output bits, ISO-8859-1 displays all the characters  in  the
1556       ISO-8859-1  map and full 8 bits is for those terminals that can display
1557       full 8 bit characters.
1558
1559    Learn keys
1560       This dialog allows you to test and  redefine  functional  keys,  cursor
1561       arrows and some other keys to make them work properly on your terminal.
1562       They often don't, since many terminal databases are incomplete or  bro‐
1563       ken.
1564
1565       You  can  move around with the Tab key and with the vi moving keys ('h'
1566       left, 'j' down, 'k' up and 'l' right).  Once you press any cursor move‐
1567       ment key and it is recognized, you can use that key as well.
1568
1569       You  can test keys just by pressing each of them.  When you press a key
1570       and it is recognized properly, OK should appear next  to  the  name  of
1571       that  key.   Once a key is marked OK it starts working as usually, e.g.
1572       F1 pressed the first time will just check that the F1  key  works,  but
1573       after that it will show help.  The same applies to the arrow keys.  The
1574       Tab key should be working always.
1575
1576       If some keys do not work properly then you won't see  OK  appear  after
1577       pressing  one  of  these.   Then you may want to redefine it.  Do it by
1578       pressing the button with the name of that key (either by the  mouse  or
1579       by Enter or Space after selecting the button with Tab or arrows).  Then
1580       a message box will appear asking you to press that key.  Do it and wait
1581       until  the  message  box  disappears.  If you want to abort, just press
1582       Escape once and wait.
1583
1584       When you finish with all the keys, you can Save them.  The  definitions
1585       for  the  keys  you  have  redefined  will  be written into the [termi‐
1586       nal:TERM] section of your ~/.config/mc/ini file (where TERM is the name
1587       of  your  current  terminal).   The  definitions  of the keys that were
1588       already working properly are not saved.
1589
1590    Virtual FS
1591       This option gives you control over the settings  of  the  Virtual  File
1592       System.
1593
1594       The  Midnight Commander keeps in memory the information related to some
1595       of the virtual file systems to speed up the access to the files in  the
1596       file system (for example, directory listings fetched from FTP servers).
1597
1598       Also, in order to access the contents of compressed files (for example,
1599       compressed tar files) the Midnight Commander needs to create  temporary
1600       uncompressed files on your disk.
1601
1602       Since  both  the  information in memory and the temporary files on disk
1603       take up resources, you may want to tune the parameters  of  the  cached
1604       information to decrease your resource usage or to maximize the speed of
1605       access to frequently used file systems.
1606
1607       Because of the format of the tar archives, the Tar filesystem needs  to
1608       read  the  whole  file  just  to load the file entries.  Since most tar
1609       files are usually kept compressed  (plain  tar  files  are  species  in
1610       extinction), the tar file system has to uncompress the file on the disk
1611       in a temporary location and then access the uncompressed file as a reg‐
1612       ular tar file.
1613
1614       Now, since we all love to browse files and tar files all over the disk,
1615       it's common that you will leave a tar file and then re-enter it  later.
1616       Since  decompression  is  slow,  the  Midnight Commander will cache the
1617       information in memory for a limited time.  When  the  timeout  expires,
1618       all  the  resources  associated with the file system are released.  The
1619       default timeout is set to one minute.
1620
1621       The FTP File System (ftpfs) allows you to browse directories on  remote
1622       FTP servers.  It has several options.
1623
1624       ftp  anonymous  password is the password used when you login as "anony‐
1625       mous".  Some sites require a valid e-mail address.  On the other  hand,
1626       you  probably  don't want to give your real e-mail address to untrusted
1627       sites, especially if you are not using spam filtering.
1628
1629       ftpfs keeps the directory listing it fetches from a  FTP  server  in  a
1630       cache.   The cache expire time is configurable with the ftpfs directory
1631       cache timeout option.  A low value for this option may slow down  every
1632       operation  on the ftpfs because every operation would require sending a
1633       request to the FTP server.
1634
1635       You can define an FTP proxy host for doing FTP.  Note that most  modern
1636       firewalls  are  fully transparent at least for passive FTP (see below),
1637       so FTP proxies are considered obsolete.
1638
1639       If Always use ftp proxy is not set, you can use the exclamation sign to
1640       enable proxy for certain hosts.  See FTP File System for examples.
1641
1642       If  this  option  is  set,  the program will do two things: consult the
1643       /usr/lib/mc/mc.no_proxy file for lines containing host names  that  are
1644       local  (if  the  host  name  starts  with  a dot, it is assumed to be a
1645       domain) and to assume that any hostnames without dots  in  their  names
1646       are  directly accessible.  All other hosts will be accessed through the
1647       specified FTP proxy.
1648
1649       You can enable using ~/.netrc file, which keeps login names  and  pass‐
1650       words for ftp servers.  See netrc (5) for the description of the .netrc
1651       format.
1652
1653       Use passive mode enables using FTP passive mode,  when  the  connection
1654       for  data transfer is initiated by the client, not by the server.  This
1655       option is recommended and enabled by default.  If this option is turned
1656       off, the data connection is initiated by the server.  This may not work
1657       with some firewalls.
1658
1659    Save Setup
1660       At startup the Midnight  Commander  will  try  to  load  initialization
1661       information from the ~/.config/mc/ini file. If this file doesn't exist,
1662       it will load the information from the system-wide  configuration  file,
1663       located  in /usr/share/mc/mc.ini. If the system-wide configuration file
1664       doesn't exist, MC uses the default settings.
1665
1666       The Save Setup command creates the ~/.config/mc/ini file by saving  the
1667       current settings of the Left, Right and Options menus.
1668
1669       If  you  activate  the  auto save setup option, MC will always save the
1670       current settings when exiting.
1671
1672       There also exist settings which can't be changed  from  the  menus.  To
1673       change  these  settings  you  have  to  edit  the  setup file with your
1674       favorite editor. See the section on Special Settings for more  informa‐
1675       tion.
1676
1677

Executing operating system commands

1679       You  may  execute commands by typing them directly in the Midnight Com‐
1680       mander's input line, or by selecting the program you  want  to  execute
1681       with the selection bar in one of the panels and hitting Enter.
1682
1683       If  you  press  Enter  over a file that is not executable, the Midnight
1684       Commander checks the extension of the selected file against the  exten‐
1685       sions  in the Extensions File.  If a match is found then the code asso‐
1686       ciated with that extension is executed. A very simple  macro  expansion
1687       takes place before executing the command.
1688
1689  The cd internal command
1690       The  cd  command  is  interpreted  by the Midnight Commander, it is not
1691       passed to the command shell for execution.  Thus it may not handle  all
1692       of  the  nice  macro  expansion  and substitution that your shell does,
1693       although it does some of them:
1694
1695       Tilde substitution.  The (~) will be substituted with your home  direc‐
1696       tory, if you append a username after the tilde, then it will be substi‐
1697       tuted with the login directory of the specified user.
1698
1699       For example, ~guest is the home directory for  the  user  guest,  while
1700       ~/guest is the directory guest in your home directory.
1701
1702       Previous  directory.  You can jump to the directory you were previously
1703       by using the special directory name '-' like this: cd -
1704
1705       CDPATH directories.  If the directory specified to the  cd  command  is
1706       not  in  the  current  directory,  then The Midnight Commander uses the
1707       value in the environment variable CDPATH to search for the directory in
1708       any of the named directories.
1709
1710       For  example  you  could  set  your  CDPATH variable to ~/src:/usr/src,
1711       allowing you to change your directory to any of the directories  inside
1712       the  ~/src  and /usr/src directories, from any place in the file system
1713       by using its relative name (for example cd  linux  could  take  you  to
1714       /usr/src/linux).
1715
1716  Macro Substitution
1717       When  accessing  a  user menu, or executing an extension dependent com‐
1718       mand, or running a command from the command line input, a simple  macro
1719       substitution takes place.
1720
1721       The macros are:
1722
1723       %i     The  indent  of  blank  space, equal the cursor column position.
1724              For edit menu only.
1725
1726       %y     The syntax type of current file. For edit menu only.
1727
1728       %k     The block file name.
1729
1730       %e     The error file name.
1731
1732       %m     The current menu name.
1733
1734       %f and %p
1735              The current file name.
1736
1737       %x     The extension of current file name.
1738
1739       %b     The current file name without extension.
1740
1741       %d     The current directory name.
1742
1743       %F     The current file in the unselected panel.
1744
1745       %D     The directory name of the unselected panel.
1746
1747       %t     The currently tagged files.
1748
1749       %T     The tagged files in the unselected panel.
1750
1751       %u and %U
1752              Similar to the %t and %T macros, but in addition the  files  are
1753              untagged.   You can use this macro only once per menu file entry
1754              or extension file entry, because next  time  there  will  be  no
1755              tagged files.
1756
1757       %s and %S
1758              The selected files: The tagged files if there are any. Otherwise
1759              the current file.
1760
1761       %cd    This is a special macro that  is  used  to  change  the  current
1762              directory  to  the  directory specified in front of it.  This is
1763              used primarily as an interface to the Virtual File System.
1764
1765       %view  This macro is used to invoke the internal  viewer.   This  macro
1766              can be used alone, or with arguments.  If you pass any arguments
1767              to this macro, they should be enclosed in brackets.
1768
1769              The arguments are: ascii to force the viewer  into  ascii  mode;
1770              hex  to force the viewer into hex mode; nroff to tell the viewer
1771              that it should interpret the bold  and  underline  sequences  of
1772              nroff;  unformatted  to  tell  the viewer to not interpret nroff
1773              commands for making the text bold or underlined.
1774
1775       %%     The % character
1776
1777       %{some text}
1778              Prompt for the substitution. An input box is shown and the  text
1779              inside  the braces is used as a prompt. The macro is substituted
1780              by the text typed by the user. The user can press ESC or F10  to
1781              cancel. This macro doesn't work on the command line yet.
1782
1783       %var{ENV:default}
1784              If  environment  variable  ENV  is unset, the default is substi‐
1785              tuted.  Otherwise, the value of ENV is substituted.
1786
1787  The subshell support
1788       The subshell support is a compile time  option,  that  works  with  the
1789       shells: bash, tcsh and zsh.
1790
1791       When the subshell code is activated the Midnight Commander will spawn a
1792       concurrent copy of your shell (the one defined in  the  SHELL  variable
1793       and if it is not defined, then the one in the /etc/passwd file) and run
1794       it in a pseudo terminal, instead of invoking a new shell each time  you
1795       execute a command, the command will be passed to the subshell as if you
1796       had typed it.  This also allows you to  change  the  environment  vari‐
1797       ables,  use shell functions and define aliases that are valid until you
1798       quit the Midnight Commander.
1799
1800       If you are using bash you can specify startup commands for the subshell
1801       in  your ~/.local/share/mc/bashrc file and special keyboard maps in the
1802       ~/.local/share/mc/inputrc file.  tcsh users may  specify  startup  com‐
1803       mands in the ~/.local/share/mc/tcshrc file.
1804
1805       When  the  subshell  code  is used, you can suspend applications at any
1806       time with the sequence C-o and jump back to the Midnight Commander,  if
1807       you  interrupt an application, you will not be able to run other exter‐
1808       nal commands until you quit the application you interrupted.
1809
1810       An extra added feature of using the subshell is that  the  prompt  dis‐
1811       played  by  the Midnight Commander is the same prompt that you are cur‐
1812       rently using in your shell.
1813
1814       The OPTIONS section has more information on how  you  can  control  the
1815       subshell code.
1816

Chmod

1818       The  Chmod  window  is  used to change the attribute bits in a group of
1819       files and directories.  It can be invoked with the C-x c  key  combina‐
1820       tion.
1821
1822       The Chmod window has two parts - Permissions and File.
1823
1824       In the File section are displayed the name of the file or directory and
1825       its permissions in octal form, as well as its owner and group.
1826
1827       In the Permissions section there is a set of check buttons which corre‐
1828       spond  to  the  file attribute bits.  As you change the attribute bits,
1829       you can see the octal value change in the File section.
1830
1831       To move between the widgets (buttons and check buttons) use  the  arrow
1832       keys  or  the  Tab key.  To change the state of the check buttons or to
1833       select a button use Space.  You can also use the hotkeys on the buttons
1834       to  quickly activate them.  Hotkeys are shown as highlighted letters on
1835       the buttons.
1836
1837       To set the attribute bits, use the Enter key.
1838
1839       When working with a group of files or directories, you  just  click  on
1840       the bits you want to set or clear.  Once you have selected the bits you
1841       want to change, you select one of the action  buttons  (Set  marked  or
1842       Clear marked).
1843
1844       Finally,  to set the attributes exactly to those specified, you can use
1845       the [Set all] button, which will act on all the tagged files.
1846
1847       [Marked all] set only marked attributes to all selected files
1848
1849       [Set marked] set marked bits in attributes of all selected files
1850
1851       [Clean marked] clear marked bits in attributes of all selected files
1852
1853       [Set] set the attributes of one file
1854
1855       [Cancel] cancel the Chmod command
1856

Chown

1858       The Chown command is used to change the owner/group of a file. The  hot
1859       key for this command is C-x o.
1860

Advanced Chown

1862       The Advanced Chown command is the Chmod and Chown command combined into
1863       one window. You can change the permissions and owner/group of files  at
1864       once.
1865

File Operations

1867       When  you  copy,  move or delete files the Midnight Commander shows the
1868       file operations dialog.  It shows the files currently  being  processed
1869       and  uses  up  to three progress bars.  The file bar indicates the per‐
1870       centage of the current file that has been processed so far.  The  count
1871       bar  shows  how  many of the tagged files have been handled.  The bytes
1872       bar indicates the percentage of the total size of the tagged files that
1873       has  been  handled.   If  the verbose option is off, the file and bytes
1874       bars are not shown.
1875
1876       There are two buttons at the bottom of the dialog.  Pressing  the  Skip
1877       button  will skip the rest of the current file. Pressing the Abort but‐
1878       ton will abort the whole operation, the rest of the files are skipped.
1879
1880       There are three other dialogs which you can run into  during  the  file
1881       operations.
1882
1883       The  error dialog informs about error conditions and has three choices.
1884       Normally you select either the Skip button to  skip  the  file  or  the
1885       Abort  button  to  abort the operation altogether.  You can also select
1886       the Retry button if you fixed the problem from another terminal.
1887
1888       The replace dialog is shown when you attempt to copy or move a file  on
1889       the  top  of an existing file.  The dialog shows the dates and sizes of
1890       the both files.  Press the Yes button to overwrite  the  file,  the  No
1891       button to skip the file, the All button to overwrite all the files, the
1892       None button to never overwrite and the Update button  to  overwrite  if
1893       the source file is newer than the target file.  You can abort the whole
1894       operation by pressing the Abort button.
1895
1896       The recursive delete dialog is shown when you try to delete a directory
1897       which  is  not  empty.   Press  the  Yes button to delete the directory
1898       recursively, the No button to skip the directory,  the  All  button  to
1899       delete  all  the  directories  and  the  None  button  to  skip all the
1900       non-empty directories.  You can abort the whole operation  by  pressing
1901       the  Abort  button.   If you selected the Yes or All button you will be
1902       asked for a confirmation.  Type "yes" only if you are really  sure  you
1903       want to do the recursive delete.
1904
1905       If  you  have  tagged  files  and perform an operation on them only the
1906       files on which the operation succeeded are untagged. Failed and skipped
1907       files are left tagged.
1908

Mask Copy/Rename

1910       The  copy/move  operations  let  you translate the names of files in an
1911       easy way.  To do it, you have to specify the correct  source  mask  and
1912       usually in the trailing part of the destination specify some wildcards.
1913       All the files matching the source mask are copied/renamed according  to
1914       the  target  mask.   If  there  are tagged files, only the tagged files
1915       matching the source mask are renamed.
1916
1917       There are other options which you can set:
1918
1919       Follow links
1920
1921       determines whether make the symlinks and hardlinks in the source direc‐
1922       tory  (recursively in subdirectories) new links in the target directory
1923       or whether would you like to copy their content.
1924
1925       Dive into subdirs
1926
1927       determines the behavior when  the  source  directory  is  about  to  be
1928       copied, but the target directory already exists.  The default action is
1929       to copy the contents of the source directory into the target directory.
1930       Enabling  this  option  causes copying the source directory itself into
1931       the target directory.
1932
1933       For example, you want to copy directory /foo  containing  file  bar  to
1934       /bla/foo,  which is an already existing directory.  Normally (when Dive
1935       into subdirs is not set), mc would copy file  /foo/bar  into  the  file
1936       /bla/foo/bar.   By enabling this option the /bla/foo/foo directory will
1937       be created, and /foo/bar will be copied into /bla/foo/foo/bar.
1938
1939       Preserve attributes
1940
1941       determines whether to preserve the permissions, timestamps and (if  you
1942       are  root)  the ownership of the original files.  If this option is not
1943       set, the current value of the umask will be respected.
1944
1945       Use shell patterns
1946
1947       When this option is on you can use the '*' and  '?'  wildcards  in  the
1948       source  mask.  They  work like they do in the shell. In the target mask
1949       only the '*' and '\<digit>' wildcards are allowed. The first '*'  wild‐
1950       card  in the target mask corresponds to the first wildcard group in the
1951       source mask, the second '*' corresponds to the second group and so  on.
1952       The '\1' wildcard corresponds to the first wildcard group in the source
1953       mask, the '\2' wildcard corresponds to the second group and so  on  all
1954       the  way  up  to  '\9'.  The '\0' wildcard is the whole filename of the
1955       source file.
1956
1957       Two examples:
1958
1959       If the source mask is "*.tar.gz", the destination is  "/bla/*.tgz"  and
1960       the  file  to  be copied is "foo.tar.gz", the copy will be "foo.tgz" in
1961       "/bla".
1962
1963       Suppose you want to swap basename and extension so that "file.c"  would
1964       become  "c.file"  and so on.  The source mask for this is "*.*" and the
1965       destination is "\2.\1".
1966
1967       Use shell patterns off
1968
1969       When the shell patterns option is  off  the  MC  doesn't  do  automatic
1970       grouping anymore. You must use '\(...\)' expressions in the source mask
1971       to specify meaning for the wildcards in the target mask. This  is  more
1972       flexible but also requires more typing. Otherwise target masks are sim‐
1973       ilar to the situation when the shell patterns option is on.
1974
1975       Two examples:
1976
1977       If  the  source  mask  is  "^\(.*\)\.tar\.gz$",  the   destination   is
1978       "/bla/*.tgz"  and  the file to be copied is "foo.tar.gz", the copy will
1979       be "/bla/foo.tgz".
1980
1981       Let's suppose you want to swap basename and extension so that  "file.c"
1982       will   become  "c.file"  and  so  on.  The  source  mask  for  this  is
1983       "^\(.*\)\.\(.*\)$" and the destination is "\2.\1".
1984
1985       Case Conversions
1986
1987       You can also change the case of the filenames.  If you use '\u' or '\l'
1988       in  the  target mask, the next character will be converted to uppercase
1989       or lowercase correspondingly.
1990
1991       If you use '\U' or '\L' in the target mask, the next characters will be
1992       converted to uppercase or lowercase correspondingly up to the next '\E'
1993       or next '\U', '\L' or the end of the file name.
1994
1995       The '\u' and '\l' are stronger than '\U' and '\L'.
1996
1997       For example, if the source mask is '*' (  Use  shell  patterns  on)  or
1998       '^\(.*\)$' ( Use shell patterns off) and the target mask is '\L\u*' the
1999       file names will be converted to have initial upper case  and  otherwise
2000       lower case.
2001
2002       You can also use '\' as a quote character. For example, '\\' is a back‐
2003       slash and '\*' is an asterisk.
2004
2005       Stable symlinks
2006
2007       commands Midnight Commander, that it should change symlinks in the tar‐
2008       get,  so that they'll point to the same location as it did before. With
2009       absolute symbolic links this does nothing, but if you have  a  relative
2010       one, it will recompute its value, adding necessary ../ and other direc‐
2011       tory parts and making the value  as  short  as  possible  (most  modern
2012       filesystems keep short symlinks inside inodes and thus don't waste much
2013       disk space).
2014
2015

Select/Unselect Files

2017       The dialog of group of files and directories selection  or  uselection.
2018       The  input  line  allow  enter the regular expression of filenames that
2019       will be selected/unselected.
2020
2021       When Files only checkbox is on, only files will be selected.  If  Files
2022       only is off, as files as directories will be selected.  When Shell Pat‐
2023       terns checkbox is on, the regular expression is much like the  filename
2024       globbing  in  the  shell  (* standing for zero or more characters and ?
2025       standing for one character). If Shell Patterns is off, then the tagging
2026       of  files  is  done  with normal regular expressions (see ed (1)). When
2027       Case sensitive checkbox is on, the selection  will  be  case  sensitive
2028       characters.  If Case sensitive is off, the case will be ignored.
2029

Internal Diff Viewer

2031       The  mcdiff  is  a visual diff tool. You can compare two files and edit
2032       them in-place (diffs are updated dynamically). You can browse and  view
2033       a  working  copy from popular version control systems (GIT, Subversion,
2034       etc).
2035
2036       Following shortcuts are available in internal diff viewer  of  Midnight
2037       Commander.
2038
2039       F1 Invoke the built-in hypertext help viewer.
2040
2041       F2 Save modified files.
2042
2043       F4 Edit file of the left panel in the internal editor.
2044
2045       F14 Edit file of the right panel in the internal editor.
2046
2047       F5 Merge the current hunk. Only the current hunk will be merged.
2048
2049       F7 Start search.
2050
2051       F17 Continue search.
2052
2053       F10, Esc, q Exit from diff viewer.
2054
2055       Alt-s, s Toggle show of hunk status.
2056
2057       Alt-n, l Toggle show of line numbers.
2058
2059       f Maximize left panel.
2060
2061       = Make panels equal in width.
2062
2063       > Reduce the size of the right panel.
2064
2065       < Reduce the size of the left panel.
2066
2067       c Toggle show of trailing carriage return (CR) symbol as ^M.
2068
2069       2, 3, 4, 8 Set tabulation size
2070
2071       C-u Swap contents of diff panels.
2072
2073       C-r Refresh the screen.
2074
2075       C-o Switch to the subshell and show the command screen.
2076
2077       Enter, Space, n Find next diff hunk.
2078
2079       Backspace, p Find previous diff hunk.
2080
2081       g Go to line.
2082
2083       Down Scroll one line forward.
2084
2085       Up Scroll one line backward.
2086
2087       PageUp Move one page up.
2088
2089       PageDown Mves one page down.
2090
2091       Home, A1 Moves to the line beginning.
2092
2093       End Moves to the line end.
2094
2095       C-Home Move to the file beginning.
2096
2097       C-End, C1 Move to the file end.
2098

Internal File Viewer

2100       The internal file viewer provides two display modes: ASCII and hex.  To
2101       toggle between modes, use the F4 key.
2102
2103       The viewer will try to use the best method provided by your  system  or
2104       the  file  type  to display the information.  Some character sequences,
2105       which appear most often in preformatted  manual  pages,  are  displayed
2106       bold and underlined, thus making a pretty display of your files.
2107
2108       When  in  hex mode, the search function accepts text in quotes and con‐
2109       stant numbers.  Text in quotes is matched exactly  after  removing  the
2110       quotes.   Each  number  matches one byte.  You can mix quoted text with
2111       constants like this:
2112
2113       "String" -1 0xBB 012 "more text"
2114
2115       Note that 012 is an octal number.  -1 is converted to 0xFF.
2116
2117       Here is a listing of the actions associated with each key that the Mid‐
2118       night Commander handles in the internal file viewer.
2119
2120       F1 Invoke the built-in hypertext help viewer.
2121
2122       F2 Toggle the wrap mode.
2123
2124       F4 Toggle the hex mode.
2125
2126       F5  Goto line.  This will prompt you for a line number and will display
2127       that line.
2128
2129       F6, /.  Regular expression search.
2130
2131       ?, Reverse regular expression search.
2132
2133       F7 Normal search / hex mode search.
2134
2135       C-s, F17, n.  Start normal search  if  there  was  no  previous  search
2136       expression else find next match.
2137
2138       C-r.   Start  reverse search if there was no previous search expression
2139       else find next match.
2140
2141       F8 Toggle Raw/Parsed mode: This will show the file as found on disk  or
2142       if  a processing filter has been specified in the mc.ext file, then the
2143       output from the filter. Current mode is always the other  than  written
2144       on the button label, since on the button is the mode which you enter by
2145       that key.
2146
2147       F9 Toggle the format/unformat mode: when format mode is on  the  viewer
2148       will  interpret  some  string sequences to show bold and underline with
2149       different colors. Also, on button label is the other mode than current.
2150
2151       F10, Esc.  Exit the internal file viewer.
2152
2153       next-page, space, C-v.  Scroll one page forward.
2154
2155       prev-page, Alt-v, C-b, Backspace.  Scroll one page backward.
2156
2157       down-key Scroll one line forward.
2158
2159       up-key Scroll one line backward.
2160
2161       C-l Refresh the screen.
2162
2163       C-o Switch to the subshell and show the command screen.
2164
2165       [n] m Set the mark n.
2166
2167       [n] r Jump to the mark n.
2168
2169       C-f Jump to the next file.
2170
2171       C-b Jump to the previous file.
2172
2173       Alt-r Toggle the ruler.
2174
2175       Alt-e to change charset of displayed text may use M-e (Alt-e).   Recod‐
2176       ing  is made from selected codepage into system codepage. To cancel the
2177       recoding you may select "<No translation>" in charset selection dialog.
2178
2179       It's possible to instruct the file viewer how to display a  file,  look
2180       at the Extension File Edit section
2181
2182

Internal File Editor

2184       The internal file editor is a full-featured full screen editor.  It can
2185       edit files up to 64 megabytes.  It is possible to  edit  binary  files.
2186       The  internal  file editor is invoked using F4 if the use_internal_edit
2187       option is set in the initialization file.
2188
2189       The features it presently supports are: block copy, move, delete,  cut,
2190       paste;  key  for  key undo; pull-down menus; file insertion; macro com‐
2191       mands; regular expression search and replace;  shift-arrow  text  high‐
2192       lighting  (if supported by the terminal); insert-overwrite toggle; word
2193       wrap; autoindent; tunable tab size;  syntax  highlighting  for  various
2194       file  types;  and  an option to pipe text blocks through shell commands
2195       like indent and ispell.
2196
2197       Sections:
2198
2199              Options of editor in ini-file
2200
2201       The editor is very easy to use and requires no tutoring.  To  see  what
2202       keys  do  what, just consult the appropriate pull-down menu. Other keys
2203       are: Shift movement keys do text highlighting.  Ctrl-Ins copies to  the
2204       file mcedit.clip and Shift-Ins pastes from mcedit.clip.  Shift-Del cuts
2205       to mcedit.clip, and Ctrl-Del deletes highlighted text. Mouse highlight‐
2206       ing also works, and you can override the mouse as usual by holding down
2207       the shift key while dragging the mouse to  let  normal  terminal  mouse
2208       highlighting work.
2209
2210       To  define  a macro, press Ctrl-R and then type out the key strokes you
2211       want to be executed. Press Ctrl-R again when  finished.  You  can  then
2212       assign the macro to any key you like by pressing that key. The macro is
2213       executed when you press Ctrl-A and then the assigned key. The macro  is
2214       also  executed  if  you  press Meta, Ctrl, or Esc and the assigned key,
2215       provided that the key is not used for any other function. Once defined,
2216       the       macro       commands       go       into       the       file
2217       ~/.local/share/mc/mcedit/mcedit.macros You can delete a macro by delet‐
2218       ing the appropriate line in this file.
2219
2220       To  change  charset of displayed text may use M-e (Alt-e).  Recoding is
2221       made from selected codepage into system codepage. To cancel the  recod‐
2222       ing you may select "<No translation>" in charset selection dialog.
2223
2224       F19 will format the currently highlighted block (plain text or C or C++
2225       code   or    another).    This    is    controlled    by    the    file
2226       /usr/share/mc/edit.indent.rc       which       is       copied       to
2227       ~/.local/share/mc/mcedit/edit.indent.rc  in  your  home  directory  the
2228       first time you use it.
2229
2230       The  editor also displays non-us characters (160+). When editing binary
2231       files, you should set display bits to 7 bits in  the  options  menu  to
2232       keep the spacing clean.
2233
2234

Options of editor in ini-file

2236       Some editor options of ini-file are described in this section.  Options
2237       are placed in [Midnight-Commander] section
2238
2239       editor_wordcompletion_collect_entire_file
2240              Search autocomplete candidates in entire of file  or  just  from
2241              begin of file to cursor position (0)
2242
2243

Screen selector

2245       Midnight Commander supports running many internal modules (such as edi‐
2246       tor, viewer and diff viewer) simultaneously and switching between  them
2247       without closing open files. Using several file managers at a time, how‐
2248       ever, is not currently supported.
2249
2250       Let's call each of these modules a screen.  There  are  three  ways  to
2251       switch between screens, using one of these global shortcuts:
2252
2253       Alt-}  switch to the next screen;
2254
2255       Alt-{  switch to the previous screen;
2256
2257       Alt-`  open a dialog window with the list of currently open screens (or
2258              use the "Screen list" menu item).
2259

Completion

2261       Let the Midnight Commander type for you.
2262
2263       Attempt to perform completion on the text before current position.   MC
2264       attempts  completion  treating the text as variable (if the text begins
2265       with $), username (if the text begins with ~), hostname  (if  the  text
2266       begins  with @) or command (if you are on the command line in the posi‐
2267       tion where you might type a command, possible completions then  include
2268       shell  reserved words and shell built-in commands as well) in turn.  If
2269       none of these matches, filename completion is attempted.
2270
2271       Filename, username, variable and hostname completion works on all input
2272       lines,  command completion is command line specific.  If the completion
2273       is ambiguous (there are more different possibilities), MC beeps and the
2274       following  action  depends  on  the  setting  of the Complete: show all
2275       option in the Configuration dialog.  If it is enabled, a  list  of  all
2276       possibilities  pops  up next to the current position and you can select
2277       with the arrow keys and Enter the correct entry.  You can also type the
2278       first  letters in which the possibilities differ to move to a subset of
2279       all possibilities and complete as  much  as  possible.   If  you  press
2280       Alt-Tab  again, only the subset will be shown in the listbox, otherwise
2281       the first item which matches all the previous characters will be  high‐
2282       lighted.   As soon as there is no ambiguity, dialog disappears, but you
2283       can hide it by canceling keys Esc, F10 and left and right  arrow  keys.
2284       If Complete: show all is disabled, the dialog pops up only if you press
2285       Alt-Tab for the second time, for the first time MC just beeps.
2286

Virtual File System

2288       The Midnight Commander is provided with a code layer to access the file
2289       system;  this  code  layer  is known as the virtual file system switch.
2290       The virtual file system switch allows the Midnight Commander to manipu‐
2291       late files not located on the Unix file system.
2292
2293       Currently  the  Midnight  Commander  is packaged with some Virtual File
2294       Systems (VFS): the local file system, used for  accessing  the  regular
2295       Unix file system; the ftpfs, used to manipulate files on remote systems
2296       with the FTP protocol; the tarfs, used to manipulate tar and compressed
2297       tar files; the undelfs, used to recover deleted files on ext2 file sys‐
2298       tems (the default file system for Linux systems), fish (for  manipulat‐
2299       ing files over shell connections such as rsh and ssh).  If the code was
2300       compiled with sftpfs (for manipulating files  over  SFTP  connections).
2301       If  the  code was compiled with smbfs support, you can manipulate files
2302       on remote systems with the SMB (CIFS) protocol.
2303
2304       A generic extfs (EXTernal virtual File System) is provided in order  to
2305       easily expand VFS capabilities using scripts and external software.
2306
2307       The  VFS switch code will interpret all of the path names used and will
2308       forward them to the correct file system, the formats used for each  one
2309       of the file systems is described later in their own section.
2310
2311  FTP File System
2312       The  FTP  File  System (ftpfs) allows you to manipulate files on remote
2313       machines.  To actually use it, you can use the FTP  link  item  in  the
2314       menu  or directly change your current directory using the cd command to
2315       a path name that looks like this:
2316
2317       ftp://[!][user[:pass]@]machine[:port][remote-dir]
2318
2319       The user, port and remote-dir elements are optional.   If  you  specify
2320       the  user  element,  the  Midnight  Commander  will login to the remote
2321       machine as that user, otherwise it will  use  anonymous  login  or  the
2322       login  name  from  the ~/.netrc file.  The optional pass element is the
2323       password used for the connection.  Using the password in the VFS direc‐
2324       tory  name  is  not recommended, because it can appear on the screen in
2325       clear text and can be saved to the directory history.
2326
2327       To enable using FTP proxy, prepend !   (an  exclamation  sign)  to  the
2328       hostname.
2329
2330       Examples:
2331
2332           ftp://ftp.nuclecu.unam.mx/linux/local
2333           ftp://tsx-11.mit.edu/pub/linux/packages
2334           ftp://!behind.firewall.edu/pub
2335           ftp://guest@remote-host.com:40/pub
2336           ftp://miguel:xxx@server/pub
2337
2338       Please check the Virtual File System dialog box for ftpfs options.
2339
2340  Tar File System
2341       The  tar  file  system  provides  you with read-only access to your tar
2342       files and compressed tar files by using the chdir command.   To  change
2343       your  directory to a tar file, you change your current directory to the
2344       tar file by using the following syntax:
2345
2346       /filename.tar/utar://[dir-inside-tar]
2347
2348       The mc.ext file already provides a shortcut for tar files,  this  means
2349       that  usually  you  just  point to a tar file and press return to enter
2350       into the tar file, see the Extension File Edit section for  details  on
2351       how this is done.
2352
2353       Examples:
2354
2355           mc-3.0.tar.gz/utar://mc-3.0/vfs
2356           /ftp/GCC/gcc-2.7.0.tar/utar://
2357
2358       The latter specifies the full path of the tar archive.
2359
2360  FIle transfer over SHell filesystem
2361       The  fish file system is a network based file system that allows you to
2362       manipulate the files in a remote machine as if they were local. To  use
2363       this,  the  other  side  has  to either run fish server, or has to have
2364       bash-compatible shell.
2365
2366       To connect to a remote machine, you just need to chdir into  a  special
2367       directory which name is in the following format:
2368
2369       sh://[user@]machine[:options]/[remote-dir]
2370
2371       The user, options and remote-dir elements are optional.  If you specify
2372       the user element, the Midnight Commander  will  try  to  login  on  the
2373       remote machine as that user, otherwise it will use your login name.
2374
2375       The available options are:
2376         'C' - use compression;
2377         'r' - use rsh instead of ssh;
2378         port - specify the port used by remote server.
2379       If  the  remote-dir  element  is present, your current directory on the
2380       remote machine will be set to this one.
2381
2382       Examples:
2383
2384           sh://onlyrsh.mx:r/linux/local
2385           sh://joe@want.compression.edu:C/private
2386           sh://joe@noncompressed.ssh.edu/private
2387           sh://joe@somehost.ssh.edu:2222/private
2388
2389  SFTP (SSH File Transfer Protocol) filesystem
2390       The SFTP file system is a network based file system that allows you  to
2391       manipulate the files in a remote machine as if they were local.
2392
2393       To  connect  to a remote machine, you just need to chdir into a special
2394       directory which name is in the following format:
2395
2396       sftp://[user@]machine:[port]/[remote-dir]
2397
2398       The user, port and remote-dir elements are optional.   If  you  specify
2399       the  user  element,  the  Midnight  Commander  will try to login on the
2400       remote machine as that user, otherwise it will  use  your  login  name.
2401       port  - specify the port used by remote server (22 by default).  If the
2402       remote-dir element is present, your current  directory  on  the  remote
2403       machine will be set to this one.
2404
2405       Examples:
2406
2407           sftp://onlyrsh.mx/linux/local
2408           sftp://joe:password@want.compression.edu/private
2409           sftp://joe@noncompressed.ssh.edu/private
2410           sftp://joe@somehost.ssh.edu:2222/private
2411
2412  Undelete File System
2413       On  Linux  systems,  if  you asked configure to use the ext2fs undelete
2414       facilities, you will have the undelete file system available.  Recovery
2415       of  deleted files is only available on ext2 file systems.  The undelete
2416       file system is just an interface to the ext2fs library to retrieve  all
2417       of the deleted files names on an ext2fs and provides and to extract the
2418       selected files into a regular partition.
2419
2420       To use this file system, you have to chdir into the special  file  name
2421       formed by the "undel://" prefix and the file name where the actual file
2422       system resides.
2423
2424       For example, to recover deleted files on the second  partition  of  the
2425       first SCSI disk on Linux, you would use the following path name:
2426
2427           undel://sda2
2428
2429       It  may  take  a while for the undelfs to load the required information
2430       before you start browsing files there.
2431
2432  SMB File System
2433       The smbfs allows you to manipulate files on remote  machines  with  SMB
2434       (or  CIFS)  protocol.   These  include  Windows for Workgroups, Windows
2435       9x/ME/XP, Windows NT, Windows 2000 and Samba.  To actually use it,  you
2436       may  try  to  use the panel command "SMB link..."  (accessible from the
2437       menubar) or you may directly change your current directory to it  using
2438       the cd command to a path name that looks like this:
2439
2440       smb://[user@]machine[/service][/remote-dir]
2441
2442       The  user,  service  and  remote-dir  elements are optional.  The user,
2443       domain and password can be specified in an input dialog.
2444
2445       Examples:
2446
2447           smb://machine/Share
2448           smb://other_machine
2449           smb://guest@machine/Public/Irlex
2450
2451  EXTernal File System
2452       extfs allows you to integrate numerous features and file types into GNU
2453       Midnight Commander in an easy way, by writing scripts.
2454
2455       Extfs filesystems can be divided into two categories:
2456
2457       1.  Stand-alone filesystems, which are not associated with any existing
2458       file.  They represent certain system-wide data  as  a  directory  tree.
2459       You  can  invoke them by typing 'cd fsname://' where fsname is an extfs
2460       short name (see below).  Examples of  such  filesystems  include  audio
2461       (list  audio  tracks  on the CD) or apt (list of all Debian packages in
2462       the system).
2463
2464       For example, to list CD-Audio tracks on your CD-ROM drive, type
2465
2466         cd audio://
2467
2468       2. 'Archive' filesystems (like rpm, patchfs and more), which  represent
2469       contents of a file as a directory tree.  It can consist of 'real' files
2470       compressed in an archive (urar, rpm) or virtual files, like messages in
2471       a  mailbox  (mailfs)  or  parts  of  a patch (patchfs).  To access such
2472       filesystems 'fsname://' should be appended to the archive  name.   Note
2473       that the archive itself can be on another vfs.
2474
2475       For example, to list contents of a zip archive documents.zip type
2476
2477         cd documents.zip/uzip://
2478
2479       In  many  aspects, you could treat extfs like any other directory.  For
2480       instance, you can add it to the hotlist or change to it from  directory
2481       history.   An important limitation is that you cannot invoke shell com‐
2482       mands inside extfs, just like any other non-local VFS.
2483
2484       Common extfs scripts included with Midnight Commander are:
2485
2486       a      access 'A:' DOS/Windows diskette (cd a://).
2487
2488       apt    front end to Debian's APT package management system (cd apt://).
2489
2490       audio  audio   CD   ripping   and   playing   (cd   audio://   or    cd
2491              device/audio://).
2492
2493       bpp    package    of    Bad    Penguin   GNU/Linux   distribution   (cd
2494              file.bpp/bpp://).
2495
2496       deb    package of Debian GNU/Linux distribution (cd file.deb/deb://).
2497
2498       dpkg   Debian GNU/Linux installed packages (cd deb://).
2499
2500       hp48   view and copy files to/from a HP48 calculator (cd hp48://).
2501
2502       lslR   browsing of lslR listings  as  found  on  many  FTPs  (cd  file‐
2503              name/lslR://).
2504
2505       mailfs mbox-style mailbox files support (cd mailbox/mailfs://).
2506
2507       patchfs
2508              extfs   to   handle   unified   and   context  diffs  (cd  file‐
2509              name/patchfs://).
2510
2511       rpm    RPM package (cd filename/rpm://).
2512
2513       rpms   RPM database management (cd rpms://).
2514
2515       ulha, urar, uzip, uzoo, uar, uha
2516              archivers (cd archive/xxxx:// where xxxx is one of: ulha,  urar,
2517              uzip, uzoo, uar, uha).
2518
2519       You  could  bind file type/extension to specified extfs as described in
2520       the Extension File Edit section.  Here is an example entry  for  Debian
2521       packages:
2522
2523         regex/.deb$
2524                 Open=%cd %p/deb://
2525

Colors

2527       The  Midnight  Commander  will  try to detect if your terminal supports
2528       color using the terminal database and your terminal name.  Sometimes it
2529       gets  confused, so you may force color mode or disable color mode using
2530       the -c and -b flag respectively.
2531
2532       If the program is compiled with the Slang  screen  manager  instead  of
2533       ncurses,  it  will  also check the variable COLORTERM, if it is set, it
2534       has the same effect as the -c flag.
2535
2536       You may specify terminals that always force color mode  by  adding  the
2537       color_terminals  variable  to  the Colors section of the initialization
2538       file.  This will prevent the Midnight Commander from trying  to  detect
2539       if your terminal supports color.  Example:
2540
2541       [Colors]
2542       color_terminals=linux,xterm
2543       color_terminals=terminal-name1,terminal-name2...
2544
2545       The  program  can be compiled with both ncurses and slang, ncurses does
2546       not provide a way to force color mode: ncurses uses just  the  informa‐
2547       tion in the terminal database.
2548
2549       The  Midnight  Commander  provides  a way to change the default colors.
2550       Currently the colors are  configured  using  the  environment  variable
2551       MC_COLOR_TABLE or the Colors section in the initialization file.
2552
2553       In  the  Colors  section,  the  default  color  map  is loaded from the
2554       base_color variable.  You can specify an alternate color map for a ter‐
2555       minal by using the terminal name as the key in this section.  Example:
2556
2557       [Colors]
2558       base_color=
2559       xterm=menu=magenta:marked=,magenta:markselect=,red
2560
2561       The format for the color definition is:
2562
2563         <keyword>=<fgcolor>,<bgcolor>,<attributes>:<keyword>=...
2564
2565       The  colors  are optional, and the keywords are: normal, selected, dis‐
2566       abled, marked, markselect, errors,  input,  inputmark,  inputunchanged,
2567       commandlinemark,  reverse, gauge, header, inputhistory, commandhistory.
2568       Button bar colors are: bbarhotkey, bbarbutton. Status bar  color:  sta‐
2569       tusbar. Menu colors are: menunormal, menusel, menuhot, menuhotsel, men‐
2570       uinactive. Dialog colors are: dnormal, dfocus,  dhotnormal,  dhotfocus,
2571       dtitle.  Error  dialog colors are: errdfocus, errdhotnormal, errdhotfo‐
2572       cus, errdtitle.  Help colors  are:  helpnormal,  helpitalic,  helpbold,
2573       helplink, helpslink, helptitle.  Viewer color are: viewbold, viewunder‐
2574       line, viewselected.  Editor colors  are:  editnormal,  editbold,  edit‐
2575       marked,  editwhitespace,  editlinestate.   Popup  menu colors are: pme‐
2576       nunormal, pmenusel, pmenutitle.
2577
2578       header determines the color of panel header,  the  line  that  contains
2579       column titles and sort mode indicator.
2580
2581       input determines the color of input lines used in query dialogs.
2582
2583       gauge  determines  the  color  of  the  filled part of the progress bar
2584       (gauge), which is used to show the user the  progress  of  file  opera‐
2585       tions, such as copying.
2586
2587       disabled determines the color of the widget that cannot be selected.
2588
2589       The dialog boxes use the following colors: dnormal is used for the nor‐
2590       mal text, dfocus is the color used for the  currently  selected  compo‐
2591       nent, dhotnormal is the color used to differentiate the hotkey color in
2592       normal components, whereas the dhotfocus color is used  for  the  high‐
2593       lighted color in the currently selected component.
2594
2595       Menus  use  the  same scheme but uses the menunormal, menusel, menuhot,
2596       menuhotsel and menuinactive tags instead.
2597
2598       Help uses the following colors: helpnormal is  used  for  normal  text,
2599       helpitalic is used for text which is emphasized in italic in the manual
2600       page, helpbold is used for text which is emphasized in bold in the man‐
2601       ual page, helplink is used for not selected hyperlinks and helpslink is
2602       used for selected hyperlink.
2603
2604       Popup menu uses following colors: pmenunormal is used for  non-selected
2605       menu  items  and as a main color of popup menu window, pmenusel is used
2606       for selected menu item, pmenutitle is used for popup menu title.
2607
2608       The possible colors are: black, gray, red,  brightred,  green,  bright‐
2609       green,  brown,  yellow, blue, brightblue, magenta, brightmagenta, cyan,
2610       brightcyan, lightgray and white. And there is  a  special  keyword  for
2611       transparent background. It is 'default'. The 'default' can only be used
2612       for background color. Another special keyword "base"  means  mc's  main
2613       colors.  When 256 colors are available, they can be specified either as
2614       color16 to color255, or as rgb000 to rgb555 and gray0 to gray23.  Exam‐
2615       ple:
2616
2617       [Colors]
2618       base_color=normal=white,default:marked=magenta,default
2619
2620       Attributes  can  be any of bold, underline, reverse and blink, appended
2621       by a plus sign if more than one are desired.  The special  word  "none"
2622       means  no  attributes,  without  attempting to fall back to base_color.
2623       Example:
2624
2625       menuhotsel=yellow;black;bold+underline
2626
2627

Skins

2629       You can change the appearance of Midnight Commander.  To do  this,  you
2630       must  specify  a  file that contain descriptions of colors and lines to
2631       draw boxes. Redefining of the colors is entirely  compatible  with  the
2632       assignment of colors, as described in Section Colors.
2633
2634       If  your  skin contains any of 256-color definitions, you should define
2635       the '256colors' key set to TRUE value in [skin] section.
2636
2637
2638       A skin-file is searched on the following algorithm (to  the  first  one
2639       found):
2640
2641              1) command line option -S <skin> or --skin=<skin>
2642              2) Environment variable MC_SKIN
2643              3)  Parameter  skin  in  section  [Midnight-Commander] in config
2644              file.
2645              4) File /etc/mc/skins/default.ini
2646              5) File /usr/share/mc/skins/default.ini
2647
2648
2649       Command line option, environment variable and parameter in config  file
2650       may contain the absolute path to the skin-file (with the extension .ini
2651       or without it). Search of skin-file will occur in  (to  the  first  one
2652       found):
2653
2654              1) ~/.local/share/mc/skins/
2655              2) @sysconfdir@/mc/skins/
2656              3) /usr/share/mc/skins/
2657
2658
2659       For getting extended info, refer to:
2660
2661              Description of section and parameters
2662              Color pair definitions
2663              Draw lines
2664              Compatibility
2665
2666
2667  Description of section and parameters
2668       Section  [skin]  contain  metainfo for skin-file. Parameter description
2669       contain short text about skin.
2670
2671
2672       Section [filehighlight] contain descriptions of color pairs  for  file‐
2673       names  highlighting.  Name of parameters must be equal to names of sec‐
2674       tions into filehighlight.ini file.  See Filenames Highlight for getting
2675       more info.
2676
2677
2678       Section [core] describes the elements that are used everywhere.
2679
2680       _default_
2681              Default  color pair. Used in all other sections if they not con‐
2682              tain color definitions
2683
2684       selected
2685              cursor
2686
2687       marked selected data
2688
2689       markselect
2690              cursor on selected data
2691
2692       gauge  color of the filled part of the progress bar
2693
2694       input  color of input lines used in query dialogs
2695
2696       inputmark
2697              color of input selected text
2698
2699       inputunhanged
2700              color of input text before first modification or cursor movement
2701
2702       commandlinemark
2703              color of selected text in command line
2704
2705       reverse
2706              reverse color
2707
2708       Section [dialog] describes the elements that are placed on dialog  win‐
2709       dows (except error dialogs).
2710
2711       _default_
2712              Default  color  for  this  section. Used [core]._default_ if not
2713              specified
2714
2715       dfocus Color of active element (in focus)
2716
2717       dhotnormal
2718              Color of hotkeys
2719
2720       dhotfocus
2721              Color of hotkeys in focused element
2722
2723
2724       Section [error] describes the elements that are placed on error  dialog
2725       windows
2726
2727       _default_
2728              Default  color  for  this  section. Used [core]._default_ if not
2729              specified
2730
2731       errdhotnormal
2732              Color of hotkeys
2733
2734       errdhotfocus
2735              Color of hotkeys in focused element
2736
2737
2738       Section [menu] describes the elements that are  placed  in  menu.  This
2739       section  describes  system  menu  (called by F9) and user-defined menus
2740       (called by F2 in panels and by F11 in editor).
2741
2742       _default_
2743              Default color for this section.  Used  [core]._default_  if  not
2744              specified
2745
2746       entry  Color of menu items
2747
2748       menuhot
2749              Color of menu hotkeys
2750
2751       menusel
2752              Color of active menu item (in focus)
2753
2754       menuhotsel
2755              Color of menu hotkeys in focused menu item
2756
2757       menuinactive
2758              Color of inactive menu
2759
2760
2761       Section [help] describes the elements that are placed on help window.
2762
2763       _default_
2764              Default  color  for  this  section. Used [core]._default_ if not
2765              specified
2766
2767       helpitalic
2768              Color pair for element with italic attribute
2769
2770       helpbold
2771              Color pair for element with bold attribute
2772
2773       helplink
2774              Color of links
2775
2776       helpslink
2777              Color of active link (on focus)
2778
2779
2780       Section [editor] describes the colors of elements placed in editor.
2781
2782       _default_
2783              Default color for this section.  Used  [core]._default_  if  not
2784              specified
2785
2786       editbold
2787              Color pair for element with bold attribute
2788
2789       editmarked
2790              Color of selected text
2791
2792       editwhitespace
2793              Color of tabs and trailing spaces highlighting
2794
2795       editlinestate
2796              Color for line state area
2797
2798
2799       Section [viewer] describes the colors of elements placed in viewer.
2800
2801       viewunderline
2802              Color pair for element with underline attribute
2803
2804
2805  Color pair definitions
2806       Any parameter in skin-file contain definition of color pair.
2807
2808       Color  pairs  described as two colors and the optional attributes sepa‐
2809       rated by ';'. First field sets the foreground color, second field  sets
2810       background  color,  third field sets the attributes.  Any of the fields
2811       may be omitted, in this case value will be  taken  from  default  color
2812       pair (global color pair or from default color pair of this section).
2813
2814       Example:
2815       [core]
2816           # green on black
2817           _default_=green;black
2818           # green (default) on blue
2819           selected=;blue
2820           # yellow on black (default)
2821           # underlined yellow on black (default)
2822           marked=yellow;;underline
2823
2824
2825       Possible  colors  (names) and attributes are described in Colors.  sec‐
2826       tion.
2827
2828
2829  Draw lines
2830       Lines sets in section [Lines] into skin-file. By default  single  lines
2831       are  used,  but you may redefine to usage of any utf-8 symbols (like to
2832       lines, for example).
2833
2834       WARNING!!!  When you build Midnight Commander with the  Ncurses  screen
2835       library  usage  of  drawing  lines is limited!  Possible only drawing a
2836       single lines.  For all questions and comments please contact the devel‐
2837       opers of Ncurses.
2838
2839
2840       Descriptions of parameters [Lines]:
2841
2842       lefttop
2843              left-top line fragment.
2844
2845       righttop
2846              right-top line fragment.
2847
2848       centertop
2849              down branch of horizontal line
2850
2851       centerbottom
2852              up branch of horizontal line
2853
2854       leftbottom
2855              left-bottom line fragment
2856
2857       rightbottom
2858              right-bottom line fragment
2859
2860       leftmiddle
2861              right branch of vertical line
2862
2863       rightmiddle
2864              left branch of vertical line
2865
2866       centermiddle
2867              cross of lines
2868
2869       horiz  horizontal line
2870
2871       vert   vertical line
2872
2873       thinhoriz
2874              thin horizontal line
2875
2876       thinvert
2877              thin vertical line
2878
2879
2880
2881  Compatibility
2882       Appointment  of color  by skin-files fully compatible with the appoint‐
2883       ment of the colors described in Colors.  section.
2884
2885       In this case, reassignment of colors has priority over  the  skin  file
2886       and is complementary.
2887
2888

Filenames Highlight

2890       Section  [filehighlight]  in  current  skin-file  contains key names as
2891       highlight groups and values as color pairs. Color pairs  is  documented
2892       in Skins section.
2893
2894       Rules  of  filenames  highlight  are  placed in /usr/share/mc/filehigh‐
2895       light.ini file (~/.config/mc/filehighlight.ini).  Name  of  section  in
2896       this  file must be equal to parameters names in [filehighlight] section
2897       (in current skin-file).
2898
2899       Keys in these groups are:
2900
2901       type   file type. If present, all other options are ignored.
2902
2903       regexp regular expression. If present, 'extensions' option is ignored.
2904
2905       extensions
2906              list of extensions of files. Separated by ';' sign.
2907
2908       extensions_case
2909              (make sense only with 'extensions' parameter) make  'extensions'
2910              rule case sensitive (true) or not (false).
2911
2912       `type' key may have values:
2913       - FILE (all files)
2914         - FILE_EXE
2915       - DIR (all directories)
2916         - LINK_DIR
2917       - LINK (all links except stale link)
2918         - HARDLINK
2919         - SYMLINK
2920       - STALE_LINK
2921       - DEVICE (all device files)
2922         - DEVICE_BLOCK
2923         - DEVICE_CHAR
2924       - SPECIAL (all special files)
2925         - SPECIAL_SOCKET
2926         - SPECIAL_FIFO
2927         - SPECIAL_DOOR
2928

Special Settings

2930       Most  of the Midnight Commander settings can be changed from the menus.
2931       However, there are a small number of settings which can only be changed
2932       by editing the setup file.
2933
2934       These variables may be set in your ~/.config/mc/ini file:
2935
2936       clear_before_exec
2937              By  default the Midnight Commander clears the screen before exe‐
2938              cuting a command.  If you would prefer to see the output of  the
2939              command  at the bottom of the screen, edit your ~/.config/mc/ini
2940              file and change the value of the field clear_before_exec to 0.
2941
2942       confirm_view_dir
2943              If you press F3 on a directory, normally MC enters  that  direc‐
2944              tory.   If this flag is set to 1, then MC will ask for confirma‐
2945              tion before changing the directory if you have files tagged.
2946
2947       ftpfs_retry_seconds
2948              This value is the number of seconds the Midnight Commander  will
2949              wait  before  attempting  to reconnect to an FTP server that has
2950              denied the login.  If the value is zero, the login  will  no  be
2951              retried.
2952
2953       max_dirt_limit
2954              Specifies  how many screen updates can be skipped at most in the
2955              internal file viewer.  Normally this value is  not  significant,
2956              because  the code automatically adjusts the number of updates to
2957              skip according to the rate of incoming keystrokes.  However,  on
2958              very  slow  machines  or  terminals  with  a  fast keyboard auto
2959              repeat, a big value can make screen updates too jumpy.
2960
2961              It seems that setting  max_dirt_limit  to  10  causes  the  best
2962              behavior, and that is the default value.
2963
2964       mouse_move_pages_viewer
2965              Controls if scrolling with the mouse is done by pages or line by
2966              line on the internal file viewer.
2967
2968       only_leading_plus_minus
2969              Allow special treatment for '+', '-', '*' in  the  command  line
2970              (select,  unselect,  reverse selection) only if the command line
2971              is empty.  You don't need to quote those characters in the  mid‐
2972              dle of the command line.  On the other hand, you cannot use them
2973              to change selection when the command line is not empty.
2974
2975       show_output_starts_shell
2976              This variable only works if you are not using the subshell  sup‐
2977              port.   When  you  use  the C-o keystroke to go back to the user
2978              screen, if this one is set, you will get a fresh shell.   Other‐
2979              wise,  pressing any key will bring you back to the Midnight Com‐
2980              mander.
2981
2982       timeformat_recent
2983              Change the time format used to display dates less than 6  months
2984              from now.  See strftime or date man page for the format specifi‐
2985              cation. If this option is absent, default timeformat is used.
2986
2987       timeformat_old
2988              Change the time format used  to  display   dates  older  than  6
2989              months  from  now  or  for dates in the future.  See strftime or
2990              date man page for the format specification. If  this  option  is
2991              absent, default timeformat is used.
2992
2993       torben_fj_mode
2994              If  this  flag  is  set,  then  the  home and end keys will work
2995              slightly different on the panels, instead of moving  the  selec‐
2996              tion to the first and last files in the panels, they will act as
2997              follows:
2998
2999              The home key will: Go up to the middle line, if below  it;  else
3000              go to the top line unless it is already on the top line, in this
3001              case it will go to the first file in the panel.
3002
3003              The end key has a similar behavior: Go down to the middle  line,
3004              if over it; else go to the bottom line unless you already are at
3005              the bottom line, in such case it will move the selection to  the
3006              last file name in the panel.
3007
3008       use_file_to_guess_type
3009              If this variable is on (the default) it will spawn the file com‐
3010              mand to match the file types listed on the mc.ext file.
3011
3012       xtree_mode
3013              If this variable is on (default is off) when you browse the file
3014              system  on  a Tree panel, it will automatically reload the other
3015              panel with the contents of the selected directory.
3016
3017       fish_directory_timeout
3018              This variable holds the lifetime of a directory cache  entry  in
3019              seconds. The default value is 900 seconds.
3020
3021       clipboard_store
3022              This variable contains path (with options) to the external clip‐
3023              board utility like 'xclip' to read text into  X  selection  from
3024              file.  For example:
3025
3026       clipboard_store=xclip -i
3027
3028       clipboard_paste
3029              This variable contains path (with options) to the external clip‐
3030              board utility like 'xclip' to print the  selection  to  standard
3031              out.  For example:
3032
3033       clipboard_pastee=xclip -o
3034
3035       autodetect_codeset
3036              This  option allows use the `enca' command to autodetect codeset
3037              of text files in internal viewer and editor. List of valid  val‐
3038              ues  can be obtain by the `enca --list languages | cut -d : -f1'
3039              command. Option must be located in the [Misc] section.
3040
3041       For example:
3042
3043       autodetect_codeset=russian
3044

Terminal databases

3046       The Midnight Commander provides a way to fix your system terminal data‐
3047       base   without  requiring  root  privileges.   The  Midnight  Commander
3048       searches in the system initialization file (the mc.lib file located  in
3049       the  Midnight  Commander library directory) and in the ~/.config/mc/ini
3050       file for the section "terminal:your-terminal-name"  and  then  for  the
3051       section  "terminal:general",  each  line  of the section contains a key
3052       symbol that you want to define, followed by an equal sign and the defi‐
3053       nition  for  the key.  You can use the special \e form to represent the
3054       escape character and the ^x to represent the control-x character.
3055
3056       The possible key symbols are:
3057
3058       f0 to f20     Function keys f0-f20
3059       bs            backspace
3060       home          home key
3061       end           end key
3062       up            up arrow key
3063       down          down arrow key
3064       left          left arrow key
3065       right         right arrow key
3066       pgdn          page down key
3067       pgup          page up key
3068       insert        the insert character
3069       delete        the delete character
3070       complete      to do completion
3071
3072       For example, to define the key insert to be the Escape + [ + O + p, you
3073       set this in the ini file:
3074
3075       insert=\e[Op
3076
3077
3078       Also now you can use extended learn keys.  For example:
3079
3080           ctrl-alt-right=\e[[1;6C
3081           ctrl-alt-left=\e[[1;6D
3082
3083
3084       This  means  that  ctrl+alt+left  sends  a \e[[1;6D escape sequence and
3085       therefore Midnight Commander interprets "\e[[1;6D" as Ctrl-Alt-Left.
3086
3087
3088       The complete key symbol represents the escape sequences used to  invoke
3089       the  completion  process,  this  is  invoked  with Alt-tab, but you can
3090       define other keys to do the same work (on those keyboard with  tons  of
3091       nice and unused keys everywhere).
3092
3093

FILES

3095       Full  paths  below  may  vary  between  installations.   They  are also
3096       affected by the MC_DATADIR environment variable. If it's set, its value
3097       is used instead of /usr/share/mc in the paths below.
3098
3099       /usr/share/mc/mc.hlp
3100
3101              The help file for the program.
3102
3103       /usr/share/mc/mc.ext
3104
3105              The default system-wide extensions file.
3106
3107       ~/.config/mc/mc.ext
3108
3109              User's  own extension, view configuration and edit configuration
3110              file.  They override the contents of the system  wide  files  if
3111              present.
3112
3113       /usr/share/mc/mc.ini
3114
3115              The  default  system-wide setup for the Midnight Commander, used
3116              only if the user doesn't have his own ~/.config/mc/ini file.
3117
3118       /usr/share/mc/mc.lib
3119
3120              Global settings for the Midnight Commander.   Settings  in  this
3121              file  affect  all  users,  whether they have ~/.config/mc/ini or
3122              not.  Currently, only terminal settings are loaded from mc.lib.
3123
3124       ~/.config/mc/ini
3125
3126              User's own setup. If this file is  present  then  the  setup  is
3127              loaded from here instead of the system-wide startup file.
3128
3129       /usr/share/mc/mc.hint
3130
3131              This file contains the hints displayed by the program.
3132
3133       /usr/share/mc/mc.menu
3134
3135              This file contains the default system-wide applications menu.
3136
3137       ~/.config/mc/menu
3138
3139              User's  own application menu. If this file is present it is used
3140              instead of the system-wide applications menu.
3141
3142       ~/.cache/mc/Tree
3143
3144              The directory list for the directory tree  and  tree  view  fea‐
3145              tures.
3146
3147       ~/.local/share/mc.menu
3148
3149              Local  user-defined  menu.  If  this file is present, it is used
3150              instead of the home or system-wide applications menu.
3151
3152       To change default root directory of MC, you can use MC_HOME environment
3153       variable.  The value of MC_HOME must be an absolute path. If MC_HOME is
3154       unset or empty, HOME variable is used. If HOME is unset  or  empty,  MC
3155       directories are get from GLib library.
3156

LICENSE

3158       This  program  is distributed under the terms of the GNU General Public
3159       License as published by the Free Software Foundation. See the  built-in
3160       help for details on the License and the lack of warranty.
3161

AVAILABILITY

3163       The    latest    version    of   this   program   can   be   found   at
3164       ftp://ftp.gnu.org/gnu/mc/.
3165

SEE ALSO

3167       ed(1), gpm(1), terminfo(1), view(1), sh(1), bash(1), tcsh(1), zsh(1).
3168
3169       The Midnight Commander page on the World Wide Web:
3170            http://www.midnight-commander.org/
3171

AUTHORS

3173       Authors and contributors are listed in the AUTHORS file in  the  source
3174       distribution.
3175

BUGS

3177       See  the  file TODO in the distribution for information on what remains
3178       to be done.
3179
3180       If you want to report a problem with the program, please send  mail  to
3181       this address: mc-devel@gnome.org.
3182
3183       Provide  a  detailed description of the bug, the version of the program
3184       you are running (mc -V displays this information), the operating system
3185       you  are  running  the  program  on.   If the program crashes, we would
3186       appreciate a stack trace.
3187
3188
3189
3190MC Version 4.8.7                 November 2016                           MC(1)
Impressum