Gnome Midnight Commander Documentation Dave Mason
dcm@redhat.com
1998,1999 Red Hat Software and David A. Wheeler This documentation is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA For more details see the file COPYING that should have been included in this distribution of the Gnome Midnight Commander.
The GNOME File Manager Introduction GNOME File Manager GMC "Gnome File Manager" GNU Midnight Commander "GNOME File Manager" GNOME includes a file manager that allows you to manipulate the files on your system in a comfortable, powerful, graphical environment. This File Manager is known as GMC for GNU Midnight Commander. GMC is based on the Midnight Commander file manager which can be run in a terminal. Midnight Commander has long been known for its power and ease of use. GMC has taken the power and ease of use from MC and added the GNOME graphical frontend. As mentioned in the previous chapter, the GNOME File Manager provides the desktop functionality for GNOME. The GNOME File Manager also provides a place to manipulate files on your system by using the GNOME File Manager window.
GNU Midnight Commander - The GNOME File Manager GMC
There are two main windows within the GNOME File Manager. On the left is the tree view, which represents all of the directories on your system by their hierarchical position. On the right is the directory window, which will show you the contents of the directory which you have selected in the tree view. To select a directory in the tree view simply use a single mouse click. This will change the main directory view, showing the files in the directory you have chosen. If there is a plus sign to the left of a directory name in the tree window, you may click on it to show subdirectories. At this point the plus sign will have changed to a minus sign. If you click on the minus sign, the subdirectory once again becomes hidden in the tree view and the plus sign reappears. GNOME File Manager Viewing Files The directry window has a few viewing options you may wish to take advantage of: the icon view and three list views, brief, detailed and custom. The icon view is the default view and will display large icons for each file. The Brief view shows the files and directories in a list. The Detailed view expands this list to include information about the files. The The Custom view is a list view that allows you to select the information you want to view about files. In the Brief, Detailed, and Custom views if you click on one of the information titles on the top of the window it will sort the files according to that information. For example, if you want to find the largest files in the directory you can click on the Size title and the files will be sorted by size from largest to smallest. One more click on the Size title will change the sorting from smallest to largest.
Moving Around the GNOME File Manager GNOME File Manager Moving around Above the tree and main file windows in the GNOME File Manager there is a Location text box. Within this text box you can type the path location of the file in which you would like to view in the main window. GNOME File Manager FTP The GNOME File Manager is also equipped to view FTP sites. To view an FTP site you will need to be connected to the Internet either through a dial up account or a network. Type the FTP address in Location text box using and the GNOME File Manager will attempt to connect to the site. Make sure you type in FTP addresses in the following manner: ftp://[site address] Above the Location text box are navigation buttons you might wish to use. These buttons with the arrow icons allow you to move within the directories adjacent to the one you are in. The left button will take you to the previous directory you were in, the middle button will take you up one level in the directory hierarchy, and the right button will take you to the next directory if you have just moved backwards. TIP You can open a secondary window by using your middle mouse button on any directory. Press the middle mouse button (or both left and right mouse buttons if you have emulation) on a directory in the main window and a new window will open showing the contents of the directory you clicked on. Selecting Files GNOME File Manager Selecting Files Selecting files is done with your mouse by clicking on the file or files in the GNOME File Manager. The file that is selected will then highlight to show you that it has been selected. GNOME File Manager Selecting multiple files There are a couple of ways to select more than one file. One way is to use the "rubber band" select by clicking and dragging the mouse cursor around several files. This action will produce a small dotted line, the "rubber band", to show you the area in which files will be selected.
"Rubber Band Select" Rubber Band Select
If you wish to be more selective about the files you are choosing, or the files you need do not reside next to one another, you may use the CTRL key to keep the files you have selected while you are selecting more. This works by selecting a file, pressing and holding the CTRL key and selecting another file. While the CTRL key is pressed you will be able to add to the "list" of files that are selected. Once you have selected multiple files by either method you may copy or move the files. You may also select all files in a directory by selecting the Select All menu item from the Edit menu. GNOME File Manager filtering You may also filter your selection by using the Select Files menu item in the Edit menu. Using Select Files will display a simple dialog which will allow you to type in criteria for your selection. In this field, the symbol * is interpreted as a wildcard, E.g., it matches any string. For example, if you would like to select all files in the directory that start with the letter D, you can type D* (note that filenames in Unix are case-sensitive).
Copying and Moving Files GNOME File Manager Copying files GNOME File Manager Moving files The default action for dragging and dropping files between the GNOME File Manager and the desktop is to move them. But you can also use drag and drop to copy a file by pressing the SHIFT key while dragging the file(s). You can also drag a file within the file manager to another directory. Select the file in the main window and drag it to the desired directory in the tree window. Note, however, that when dragging to the tree window the default action is to copy the file. As you drag the file to the tree window, you will see a plus sign appear to remind you that theh file will be copied. You can also use drag and drop to copy directories the same way as you did for files. Again note the plus sign signifying that the directory will be copied, not moved. GNOME File Manager Linking files You may also bring up a menu which lets you decide what action to perform with a drag by using the middle mouse button to drag a file or pressing the ALT key while dragging a file. Once you release the drag you will get a pop-up menu which contains the options Copy, Move, Link, and Cancel Drag.
The Move Dialog Move Dialog
GNOME File Manager Moving files To use the move dialog you simply type in the path where you wish to move the file. If you want to rename the file you may type the new name of the file in the path string. The Copy dialog looks and works exactly the same way as the Move/rename dialog.
If the file you are moving is a symbolic link — that is, a virtual link to where the file actually resides (called a shortcut in some other operating systems) — you may select the Advanced Options tab and select Preserve symlinks. Selecting this will make sure the link is preserved despite the move. It is recommended that you use this method of moving a symbolic link.
Renaming Files GNOME File Manager Renaming files Renaming files in the GNOME File Manager window or on the desktop can be achieved in two ways. One method of renaming a file is to right mouse click on the file and choose the Properties menu item from the pop-up menu. In the Filename text box you may type in the new name as you wish it to appear.
File Properties File Properties
A shortcut method to rename a file is to slowly double click on the filename in the icon view or on the desktop. Make sure the double-click is slow so you do not launch the file but you simply highlight and then click again. At this point the name of the file will enter into the editing mode, your mouse cursor will change to an editing line, and you can type in the new name.
Launching Applications From the GNOME File Manager GNOME File Manager Launching applications from The GNOME File Manager allows you to launch applications from the main window by simply double clicking your mouse on a file which has an application associated with it. You can change the way file types are handled by reading GNOME File Manager Open with If the file does not have an associated application you can right mouse click on the file and select Open with from the pop-up menu. This will bring up a dialog that allows you to define the application which will launch the file. For example, if you want to edit a file named test.txt with Emacs (a popular text editor), you can right mouse click on test.txt and choose Open with. When you get the Open with dialog box simply type in emacs in front of the test.txt file name. When you press OK Emacs will open the file.
The Open With Dialog Open With Dialog
File Properties and Actions GNOME File Manager File properties For any file in the main file display you may right mouse click on it and choose a variety of properties and actions for it from the pop-up menu: Open - This will open the file with the default application associated with it. You may read more about editing these associations in . Open With - You may open a file with any application using this menu item. You may read more about this in . View - This will view the file with a basic text viewer. Edit - This will launch an editor to edit the file. The editor launched is determined by the application associated with that file type. You may read more about editing this association in . Copy - This will copy the file to the clipboard so that it can be pasted elsewhere. Delete - This will delete the file. Move - This will bring up the Move dialog, which will allow you to move the file. You can read more about this dialog and moving files in . Properties - The Properties menu item will launch the properties dialog. The Properties dialog allows you to edit and view the properties for the selected file. The Properties dialog consists of three tabs, Statistics, Options, and Permissions.
File Properties File Properties
Statistics - This tab will show you the file information including the name, type, size, and history. You may change the name of the file in the File Name text box. Options - This tab will allow you to change the action options for the file. You can define how to open, view, and edit the file. If you need to open it in a terminal window you may select the Needs terminal to run checkbox. NOTE If you bring up the Properties dialog from an icon on the desktop you will be able to change the icon for that file in the Options tab. Permissions - This tab allows you to change the permissions and ownership of a file if you have access to do so. You may select Read, Write, and Exec permissions for the User, Group, and Others. You may also set the UID, GID and Sticky as well as define who owns the file.
Changing Your Preferences in The File Manager GNOME File Manager Preferences There are many settings you can configure for the GNOME File Manager. These settings may be accessed from the GMC Preferences dialog. You may launch this dialog by selecting the Preferences menu item from the Edit menu. The GMC Preferences dialog is divided into Five major sections: File Display, Confirmation, Custom View, Caching Optimizations, and VFS. File Display
File Display Preferences File Display Preferences
GNOME File Manager Display The File Display tab allows you to change the way files are displayed in GMC. Show backup files - This will show any backup file that might be on your system. GNOME File Manager Hidden Files GNOME File Manager Show hidden files Show hidden files - This will show all "dot files" or files that begin with a dot. This files typically include configuration files and directories. Mix files and directories - This option will display files and directories in the order you sort them instead of always having directories shown above files. Use shell patterns instead of regular expressions - This option is for advanced users only. If you are unfamiliar with Regular Expressions you should not use this option. If you are familiar with how to create regular expressions you may select this option to use them in your sorts and filters.
Confirmation
Confirmation Preferences Confirmation Preferences
GNOME File Manager Confirmations This tab allows you to change which functions ask for your confirmation before continuing. Confirm when deleting file - This will bring up a confirmation screen before deleting a file. Confirm when overwriting files - This will bring up a confirmation screen before overwriting a file. Confirm when executing files - This will bring up a confirmation screen before executing a file. Show progress while operations are being performed - This will bring up a progress bar while certain operations are being performed such as copying, moving, deleting, etc.
VFS
VFS Preferences VFS Preferences
GNOME File Manager VFS Virtual File System "GNOME File Manager - VFS" This tab allows you to configure the options for your Virtual File System. The Virtual File System allows you to manipulate files that are not located on your local file system. There are different version of the VFS including ftpfs and tarfs. The ftpfs allows you to work on FTP sites while the tarfs gives you access inside .tar files. NOTE The .tar file is the standard UNIX archive format VFS Timeout - This will determine how long you will be connected to any VFS without activity. The timeout is measured in seconds. Anonymous FTP password - This allows you to set a password for logging into anonymous FTP sites. Usually you will want to make this your email address. Always use FTP proxy - If you need to use a proxy to connect to FTP sites you will want to enable this.
Caching
Caching Preferences Caching Preferences
This tab allows you to configure items that will enhance the speed of GMC by using caching. Fast directory reload - This option will store directory information in cache so that it can load faster. IMPORTANT If you enable the Fast directory reload you may experience problems with not seeing new files that have been added to directories. Compute totals before copying files - This will make GMC determine the number of files you are copying before it performs the task so that it can give you information about the process as its happening. FTP directory cache timeout - This option will keep recently visited FTP site information in cache for the amount of time you specify. The time is measured in seconds. Allow customization of icons in icon view - This will allow you to change the icons in the icon view by right mouse clicking on them and selecting the Properties menu item. You can always change the icons of items that are on your desktop but you can only change the icons in the icon view with this option turned on. IMPORTANT Turning on the Allow customization of icons in icon view function may result in a slower system.
Custom View GNOME File Manager Custom View The Custom View dialog allows you to set the way you would like the Custom View to look in the GNOME File Manager.
The Custom View Dialog The Custom View Dialog
There are two main columns in the Custom View, the Possible Columns and the Displayed Columns. The Possible Columns list includes all of the information types that can be displayed. If you would like to include one, you may press the Add button and it will be added to the Displayed Columns list. The Displayed Columns list shows you the current information types that will be included in your Custom View. If you wish to remove any you may press the Remove button. If you would like to re-arrange the items in the Displayed Columns list you may drag them to the desired location with your mouse.
Menu Guide to the GNOME File Manager GNOME File Manager menus In this section each menu item in the GNOME File Manager will be described. Tip All menus in the GNOME File Manager are enabled with the tear-away feature. If you would like any menu to "float" on the desktop in its own window simply select the perforation line at the top of the menu. File - The File Menu contains items associated with files and higher level activity. New Window - This will open a new File Manager Window. Open - This will open the file you have selected with your mouse cursor. Copy - This will launch the Copy dialog to enable you to copy the selected file to a destination you choose. Move - This will launch the Move/rename dialog to enable you to rename the selected file or move it to a destination you choose. Delete - This will delete the file you have selected. Close - This will close the GNOME File Manager Edit - The Edit menu contains items that are associated with editing and selecting files. Select All - This will select all of the files in the main window. Select Files - This will launch a simple dialog box which will allow you to specify a selection pattern. For Example, if you wish to select all files beginning with the letter D you can simply type D* and press OK. Invert Selection - This will invert the current selection. For example, if you have 7 files selected in a directory with 10 files, selecting Invert Selection will select the three remaining files and unselect the 7 files that were previously selected. Rescan Directory - This will rescan the current directory in case the files in the directory have changed. Preferences - This will launch the Preferences dialog so that you can customize the GNOME File Manager. Layout - This menu contains items that are associated with the layout in GNOME File Manager. Sort By - This will launch a dialog box which will allow you to select how you wish the files to be sorted in the current directory. You may sort by one of the following: Name File Type Size Time Last Accessed Time Last Modified Time Last Changed Filter View - This will bring up a simple dialog which allows you to view only files with names matching a pattern. For example, if you wish to view only files in the directory that start with the letter D you can type D* into the dialog and press OK. If you wish to see all files again you will need to launch the Filter View dialog again and clear the dialog or type in a *. Icon View - Selecting this will display the files in the main window as large icons. Partial View - Selecting this will display the files in the main window as a list with only file names. Full View - Selecting this will display the files in the main window as a list with all file information. Custom View - The Custom View menu item switches the main window to the Custom View which is a list view displaying the information about your files that you specify. To customize the Custom view you will need to use the Custom View Editor in the Preferences dialog. You may read more about the Preferences dialog in . Commands - The Command menu contains items that are commands to run on files in the GNOME File Manager. Find File - Find File brings up a dialog which allows you to search for particular files on your system. Edit mime types - This option will launch the GNOME Control Center Capplet that allows you to edit Mime Types for GNOME. Mime types determine, among other things, what application will handle particular file types. You can read more about mime types in Run Command - This menu item allows you to run a command from GMC. Run Command in panel - This menu item lets you run preloaded commands or commands you specify within the directory that you are currently in. Such commands might be to find SUID or SGID programs, etc. Exit - This will allow you to exit the GNOME File Manager. IMPORTANT This will exit all GNOME File Manager processes which include the GNOME Desktop. If you exit you will lose all functionality on your desktop. This action is not recommended. If you wish to close the current window, use the File/Close button. A Drag and Drop Tour of GNOME GNOME Drag and Drop There are many tips and tricks to the Desktop in GNOME. The Drag and Drop functionality extends to many areas of GNOME making it easy to interconnect GNOME in many interesting ways. Below is a series of tips and tricks to using GNOME Drag and Drop. This is a good tour of GNOME and will show you how to utilize GNOME to its fullest extent. Drag a Color onto the Panel - Whenever you have a color selector displayed you may drag a color from the selected color bar to the Panel and it will change the Panel to that color. Drag a Pixmap to the Background Selector - If you would like to change the background to an image, you can drag that image from your GNOME File Manager to the Monitor Image in the Background Capplet of the Control Center and it will change to that image. Drag to an Application - Many GNOME compliant applications will accept drag and drop. If you would like to open a file in Gnumeric, a GNOME compliant spreadsheet application, you may simply drag the file from the GNOME File Manager onto Gnumeric and it will open the file. The same is true for applications built using Motif. You may drag a saved URL onto Netscape 4x and it will open the URL. This can be very useful if you are working within the GNOME File Manager and wish to quickly open a file. Adding an Application Launcher to the Panel - If you would like to add an application launcher to the Panel you may drag and drop any executable file from the GNOME File Manager, or the Desktop, onto the Panel. This will display the Create Launcher applet dialog box which will allow you to select a name and an icon for that launcher. Dragging Files - There are many ways to use drag and drop to help you manage your system. You can open two GNOME File Manager windows to two different directories then drag files between the two windows to copy, move, or link files. You can drag files from the File Manager to the desktop to make it more accessible. Use the middle mouse button or the right and left mouse buttons together and Drag a directory folder to the desktop. Choose the link option from the pop-up menu to make a link to the desktop. This will give you a quick way to launch the File Manager to that directory. Dragging Directories - You can drag a directory out of the GNOME File Manger and place it on the Panel. This will create a new menu which allows you easy access to the files in that directory. You may drag any sub menu from the Main Menu to the panel and a new menu launcher is added to the panel. This allows easier access to that sub-set of menus.