exit from pyview by ESC
[lfm.git] / README
blobb8cbe2b1f849d72b4ff34d1aca3131e07150047f
1 =======================
2 lfm - Last File Manager
3 =======================
5 :Author: Iñigo Serna, inigoserna AT telefonica DOT net
7 :Version: 2.0, September 3rd. 2007
9 :Home page: http://www.terra.es/personal7/inigoserna/lfm/
11 :License: \(C\) 2001-7, Iñigo Serna
13           This software has been realised under the `GPL License`__ version 3
14           or later, read the COPYING_ file that comes with this package for
15           more information. 
17           There is NO WARRANTY.
19 :Last update: Mon Sep  3 22:50:48 2007
22 .. contents:: Table of Contents
25 Introduction
26 ============
27 **Last File Manager** is a simple but powerful file manager for the
28 UNIX console. It has been developed with the ol' good `Midnight
29 Commander`__ as model.
31 Some of the features you can find in *lfm*:
33 - console-based file manager for UNIX platforms
34 - 1-pane or 2-pane view
35 - bookmarks
36 - vfs for compressed files
37 - dialogs with entry completion
38 - fast access to a shell
39 - direct integration of find/grep, df and other tools
40 - tabs per pane
41 - color files by extension [Andrey Skvortsov]
42 - fast file viewer with text and binary modes
43 - ...and many others
46 From version 0.6 and up *lfm* package also contains **pyview**, a
47 text / hex file viewer to be used with or without *lfm*. 
48 Read README.pyview_ for more info about it.
50 Some screenshots:
53   **lfm**:
55   .. image:: lfm.png
58   **pyview**:
60   .. image:: pyview.png
64 Type `lfm --help` or `pyview --help` for a complete list of options.
66 Program preferences are saved in `~/.lfmrc` file.
67 When the program starts the first time, it tries to discover the location
68 of some apps in your system to configure *lfm* automatically, but it's not 
69 perfect, so you should take a look to the configuration (`General Menu [F9] 
70 -> Edit Configuration [c]`) and change it according to your preferences.
73 Requirements
74 ============
75 *Lfm* and *Pyview* are written in Python_ and require curses module.
76 It needs Python v2.3 or higher, it won't work with older versions.
78 Since version 0.90, *lfm* needs ncurses >= v5.x for the handling 
79 of terminal resizing.
81 All modern UNIX flavours (Linux, \*BSD, Solaris, etc) should run it without 
82 problems. If they appear please notify me.
84 Note that python curses module should be linked against ncursesw library 
85 (instead of ncurses) to get wide characters support. This is the usual case 
86 in later versions of Linux distributions, but maybe not the case in older 
87 Linux or other UNIX platforms. Thus, expect problems when using multibyte 
88 file names (f.e. UTF-8 or latin-1 encoded) if your curses module isn't 
89 compiled against ncursesw. Anyway, I hope this issue will disappear with new 
90 releases of those platforms, eventually.
92 Also, take a look at TODO_ file to see bugs and *not-implemented-yet* (tm) 
93 features.
96 Download & Installation
97 =======================
98 .. sidebar:: Files: all versions
99    :class: warning
101    +---------+------------------+------------+
102    | Version |       File       |    Date    |
103    +=========+==================+============+
104    |   2.0   | lfm-2.0.tar.gz_  | 2007/09/03 |
105    +---------+------------------+------------+
106    |   1.0   |  Never released  |   ~2006    |
107    +---------+------------------+------------+
108    |   0.92  |  Never released  |   ~2005    |
109    +---------+------------------+------------+
110    |   0.91  | lfm-0.91.tar.gz_ | 2004/07/03 |
111    +---------+------------------+------------+
112    |   0.90  |  Never released  |            |
113    +---------+------------------+------------+
114    |   0.9   | lfm-0.9.tar.gz_  | 2002/09/05 |
115    +---------+------------------+------------+
116    |   0.8   | lfm-0.8.tar.gz_  | 2002/03/04 |
117    +---------+------------------+------------+
118    |   0.7   | lfm-0.7.tar.gz_  | 2001/11/30 |
119    +---------+------------------+------------+
120    |   0.6   |  Never released  |            |
121    +---------+------------------+------------+
122    |   0.5   | lfm-0.5.tar.gz_  | 2001/08/07 |
123    +---------+------------------+------------+
124    |   0.4   | lfm-0.4.tar.gz_  | 2001/07/19 |
125    +---------+------------------+------------+
127    Read about NEWS_ or ChangeLog_
130 'lfm' is very easy to install, just keep next steps:
132 1. Download sources_
133 2. Uncompress file
134 3. Build:
135     `$ python setup.py build`
136 4. Install, as root:
137     `# python setup.py install`
138 5. Run it:
139     `$ lfm`
141 To let 'lfm' to change to panel's current directory after quiting with
142 `q`, `Q` or `F10` keys, you must add next code to `/etc/bashrc` or to
143 your `~/.bashrc`::
145     lfm()
146     {
147         /usr/bin/lfm "$*"               # type here full path to lfm script
148         LFMPATHFILE=/tmp/lfm-$$.path
149         cd "`cat $LFMPATHFILE`"
150         rm -f $LFMPATHFILE
151     }
153 If you don't use bash or csh shell, above lines could differ.
156 Upgrading
157 =========
158 If you upgrade from any older versions, please remove first `~/.lfmrc` to 
159 regenerate a valid configuration as file format has changed. I advise you 
160 to make a backup copy before.
162 Also, note that some keys have changed since previous versions. 
163 Read carefully following section.
166 Keys
167 ====
168 These are the complete list of key bindings:
170 + **Movement**
171     - cursor_up, k, K
172     - cursor_down, j, J
173     - previous page, backspace, Ctrl-B
174     - next page, space, Ctrl-F
175     - home, Ctrl-A: first file
176     - end, Ctrl-E: last file
177     - cursor_left, h: upper dir
178     - cursor_right, l: enter dir / vfs
179     - g, G: go to directory
180     - Ctrl-S: go to file in current panel
181     - 0..9: go to bookmark #
182     - ~: go to home directory #
183     - Ctrl-D, Ctrl-\\: select bookmark # from menu
184     - b, B: set bookmark #
186 + **Panes**
187     - tab: other pane
188     - .: toggle 1/2 panes
189     - ,: Ctrl-U: change panes position (left->right, right->left)
190     - =: show same directory in both panes
192 + **Tabs**:
193     - :: new tab
194     - !: close tab
195     - <: go to left tab
196     - >: go to right tab
198 + **Selections**
199     - insert: select item and go to next file
200     - +: select group
201     - -: deselect group
202     - \*: invert selection
204 + **Files / Directories operations**
205     - t, T: touch file
206     - L: create link
207     - Ctrl-L: edit link
208     - F3: view file
209     - F4: edit file
210     - F5: copy file/dir/selection
211     - F6: move file/dir/selection
212     - F12: easy way to rename file/dir/selection
213     - F7: make directory
214     - F8, del: delete file/dir/selection
215     - enter: execute file, enter dir / vfs or view 'specially' depending on the extension of the regular file. It is executed in a thread that can be stopped and captures output
216     - i, I: show file info
218 + **Other**
219     - #: show directories size
220     - s, S: sort files
221     - /: find/grep files
222     - @: do something on file. Output is not captured
223     - Ctrl-O: open shell. Type 'exit' to return to lfm
224     - Ctrl-T: tree
225     - F2: file menu
226         - @: do something on file(s)
227         - i: file(s) info
228         - p: change file permissions, owner, group
229         - g: gzip/gunzip file(s)
230         - b: bzip2/bunzip2 file(s)
231         - x: uncompress .tar.gz, .tar.bz2, .zip, .rar
232         - u: uncompress .tar.gz, etc in other panel
233         - c: compress directory to .tar.gz
234         - d: compress directory to .tar.bz2
235         - z: compress directory to .zip
236         - r: compress directory to .rar 
237     - F9: general menu 
238         - /: find/grep file
239         - #: show directories size
240         - s: sort files
241         - t: tree
242         - f: show filesystems info
243         - o: open shell
244         - c: edit configuration
245         - r: regenerate programs
246     - Ctrl-R: refresh screen
247     - F1: help
248     - q, Q, F10: exit changing to current path
249     - Ctrl-Q: quit
252 + Keys in *EntryLine* window:
253     - up, down: historic
254     - enter: return path
255     - Ctrl-T: change to next entry or button
256     - tab: complete
257     - Ctrl-W: delete leftwards until / or beginning
258     - Ctrl-D: delete all
259     - left, right, home, end, backspace, del, insert, ...
260     - Ctrl-C, ESC: quit
262 + Keys in *SelectItem* window:
263     - up, k, K
264     - down, j, J
265     - previous page, backspace, Ctrl-B
266     - next page, space, Ctrl-F
267     - home, Ctrl-A
268     - end, Ctrl-E
269     - Ctrl-S: go to file/dir
270     - enter: return path
271     - Ctrl-C, q, Q, ESC: quit
273 + Keys in *Tree* panel:
274     - down, j, K: down within current depth, without going out from directory
275     - up, k, K: up within current depth, without going out from directory
276     - previous page, backspace, Ctrl-B: same as up but page-size scroll
277     - next page, space, Ctrl-F: same as down but page-size scroll
278     - home, Ctrl-A: first directory
279     - end, Ctrl-E: last directory
280     - left: go out from directory
281     - right: enter in directory
282     - enter: return changing to directory
283     - Ctrl-C, q, Q, F10, ESC: quit
288 You can navigate inside some special files (known as vfs files in lfm) just 
289 *entering into* them (press *enter* or *cursor_right* when the cursor bar is
290 over one of these files). By now, supported types are `.tar.gz`,
291 `.tar.bz2`, `.zip` and `.rar` files. 
293 The virtual directory name ('path_to_vfs_file#vfs/dir') is not propagated, so 
294 tmpdir (`/tmp/@6421.2/dir`) is showed in the copy/move/... dialogs or when
295 view/edit/... a file, but this is just an estetic issue.
297 When returning from one of such vfs files, a question dialog appears asking to
298 allow you to regenerate the vfs file and update all changes (i.e., it is 
299 compressed again, so it could be slow in some machines), but `lfm` checks if it 
300 can do first, to avoid waste of time. This behaviour (rebuild or not rebuild, ask 
301 it or not) can be modified in the configuration file. By default the question is
302 showed but it's set to *not regenerate vfs*.
303 In case of `panelize` vfs type (after find/grep), deleted / moved files
304 are not deleted / moved in real path.
307 History
308 =======
309 Many many years ago I began to write a program like this in C, but after
310 some weeks of coding I never finished it... I'm too lazy, yes.
311 Then I saw the light and I started writing `lfm` to learn python_.
313 Code evolved and application got more and more features, used by many
314 people around the world on different UNIX systems.
316 But after the release of version 0.91 (June 2004) they were not more releases.
317 Not that I had stopped working on *lfm*, new code was written, tested,
318 rewritten again... silently... but different reasons made me to postpone public
319 releases... code refactoring, a new essential feature, source cleaning,
320 a wedding, a child, ahem... more code refactoring....
322 Anyway, from now on I'll do my best to release often.
325 Thanks
326 ======
327 Thanks are obviously due to the whole python community, specially to GvR 
328 (of course! ;-) and all the people who answered my questions in c.l.p.
330 It's a great pleasure to code in a language like this.
332 Alexei Gilchrist, for his cfm program from which I took some ideas.
334 Midnight Commander developers, whose program was the guide.
336 And also to all the people who have contributed with ideas, reporting
337 bugs and code over these years: Antoni Aloy, Sebastien Bacher, Witold
338 Bołt, Fabian Braennstroem, Ondrej Certik, Kevin Coyner, Tim Daneliuk,
339 Mike Dean, Christian Eichert, Steve Emms, Stephen R. Figgins, Ana
340 Beatriz Guerrero Lopez, Tjabo Kloppenburg, Zoran Kolic, Max Kutny,
341 Bartosz Oler, Piotr Ozarowski, Jerome Prudent, Mikhail Ramendik, Rod,
342 Daniel T. Schmitt, Robin Siebler, Andrey Skvortsov, Espartaco Smith,
343 Jörg Sonnenberger, Tim Terlegård, Edd Thompson, Walter van den Broek,
344 Alejandro Weil and many others...
345 You have made posible to run *lfm* in all those platforms!
349 .. _sources: lfm-2.0.tar.gz
350 .. _README.pyview: README.pyview.html
351 .. _TODO: TODO
352 .. _NEWS: NEWS
353 .. _ChangeLog: ChangeLog
354 .. _COPYING: COPYING
355 .. _GPL: http://www.gnu.org/licenses/licenses.html#GPL
356 .. _mc: http://www.ibiblio.org/mc/
357 .. _python: http://www.python.org
358 __ GPL_
359 __ mc_
360 .. _lfm-2.0.tar.gz: lfm-2.0.tar.gz
361 .. _lfm-0.91.tar.gz: lfm-0.91.tar.gz
362 .. _lfm-0.9.tar.gz: lfm-0.9.tar.gz
363 .. _lfm-0.8.tar.gz: lfm-0.8.tar.gz
364 .. _lfm-0.7.tar.gz: lfm-0.7.tar.gz
365 .. _lfm-0.5.tar.gz: lfm-0.5.tar.gz
366 .. _lfm-0.4.tar.gz: lfm-0.4.tar.gz