= A List of Some Important Tools INTRODUCTION This document tries to provide links to useful programs (also called 'tools') which are available on the Internet (almost always free and 'open source') and which may be useful in your day-to-day work. (They are for me). NORMAL USER TOOLS http://winscp.vse.cz/eng/ This is a client for 'secure ftp' or sftp, which is part of the ssh protocol. This program runs on windows and provides a graphical user interface to a secure ftp server. It has all the features you would expect of a graphical ftp program. It is in active development (april 2003) http://www.chiark.greenend.org.uk/~sgtatham/putty/ This is the 'putty' tool, which allows you to communicate with the computer which is located in the 'local' in Barcelona, in a 'secure' way. http://www.pgpi.org/ The 'pretty good privacy' (pgp) tool. This allows you to send emails without anybody except the recipient being able to see them. http://sourceforge.net/projects/j-ftp The j-ftp program, which is an open source ftp program which allows you to use 'secure' ftp (also known as sftp) or 'normal' ftp. This is written in java an so should work on MS Windows and Linux. There are several other programs on the Internet also called 'jftp' or something similar, but don't be fooled, this is the one, man. It does not appear to have any online documentation. Has a nice graphical user interface, and an output window which tells you what is going on, in terms of FTP comands. On MS Win2000 it has a flickering problem when transfering files. It does not appear to have a cumulative total of the number of bytes which have been transfered. ADMINISTRATIVE AND TECHNICAL TOOLS http://www.mysql.com/products/mysqlcc/index.html A thing called 'MySql Control Center' which is a nice MS Windows GUI tool/client for the MySql Datbase ("it has dolphins on it": nick reddel) A thing called 'webmin' which is a web-based remote administrative tool for Linux. A BRIEF HISTORY OF AN ODD THING CALLED VIM http://www.vim.org/ Note: Vim, the text editor, requires a certain amount of time and patience in order to show its benefits. If you don't want to spend that time, Vim will probably only cause you intense frustration. Vim is a very powerful and yet very 'obscure' text editor called 'vim'. It is an improved version of another even more obscure text editor named 'vi' which in turn is an improvement on a ridiculously obscure text editor called 'ex' which in turn is an improvement on a beyond-the-pale editor known as 'ed'. When I say obscure, I mean that to the new user it is not immediately apparent how to do anything at all. Even how to enter text is not obvious. In keeping with standard unix/linux practice all these short and cryptic names actually 'stand' for something. To be specific: 'ed' stands for 'editor', 'ex' stands for 'extended editor', 'vi' stands for 'visual editor' and 'vim' stands for 'vi improved'. All these text editors has been developed in the 'unix' environment but all are now available on Microsoft Windows. 'ed' is an editor in the same class as the very ancient DOS editor known as 'edlin' and has the same sort of interface (but many more capabilities). In this interface you cant actually use the cursor keys to move around in the text and edit it using keys like 'delete', 'backspace' or anything like that. You have to type commands which affect the text in some way. For example, if you type the comand '45d' then 45th line of the text file will be deleted. This may seem to the uninitiated a really bad way of editing text, and they may well be right. 'Ex' has roughly the same interface as 'ed' but again many more capabilities. 'Vi' introduces some of the cursor key movements and interactive editing that an sane person expects. However, I don't recomend vi for the simple reason that it contains no built in 'help' system (apart from some terribly terse and confusing command summaries). For this reason, obtain 'vim' from the address above. It is available for MS Windows in a 'GUI' form and also in a 'console' or 'command box' form, as well as for unix/linux. It is also available for Macintosh (definitely OSX and possibly earlier operating systems). Vim has a really good help system, just type ':help' to see it. Vim can seem strange and annoying at first to the user coming from the Microsoft World and from DOS text editors like 'edit'. The user coming from the Microsoft Environment general feels as if he or she has been forceably propelled back through time to the era of 'WordStar' but this is not really an accurate impression. Vim has great capabilities. If you only edit text occasionally, it is probably not the editor to use since it is not particularly 'intuitive'. But if you spend a large amount of time editing text, then it can be very useful. The alternatives to vim on unix/linux are 'Emacs' which is the other famous Unix editor. There are also many other text editors which are available for unix/linux. 'Pico' or 'Nano' is one simple text editor which the new user should be able to use (almost) immediately and which is usually installed on every unix/linux system. For those who desire something very similar to the DOS 'edit' program (or to the old Borland Text Program Editors) there is a program called 'setedit' available on Linux. A very large number of reference and tutorial pages are available on the Internet explaining and eulogising vi and vim. This is one of the advantages of using tools that are have been around in one form or another for about a quarter of a century; there is a great deal of collective experience available to help you. The url above contains enormous amounts of 'tips' and 'scripts' to customize vim. As an historical note, many of the strange things about vim stem from the fact that it was written using a very very 'low-end' computer using a 900 baud modem. (It was written by somebody called Bill Joy) http://www.unb.ca/documentation/UNIX/tips/vim/ A Vim Tutorial Page http://www.tuxfiles.org/linuxhelp/vimcheat.html A short but useful command reference sheet http://www.geocities.com/h2lee/vim.html Another slightly better command reference sheet http://www.vim.org/tips/tip.php?tip_id=305 Some vim ftp commands. That is, how to use Vim to edit a remote file. And multiple line searching (for patterns that may be on more that one line). Generallly some very interesting tips I have not been able to get ftp writing to work under MS Windows (with the :Nwrite command) although ftp reading does work. http://users.erols.com/astronaut/vim/index.html#vimlinks_scripts Some scripts for vim and some spelling dictionaries (word lists) including some obscure languages such as 'galician' which is a Spanish 'dialect' although the Galicians would probably say that it is a language not a dialect. Pretty comprehensive and good. http://www.vim.org/tips/tip.php?tip_id=285 How to map the key to something else when using 'vim' http://www.vim.org/tips/tip.php?tip_id=64 An example of using an 'expression' in vim (like 'the current file') in order to do something. The following two lines do a 'cat' of the current file -->> :let _f=expand("%:p") :exec "!cat " . _f --<< The following command filters the current file into HTML :exec "!plaintext2html.sh " . expand("%:p") . " > " . expand("%:p:r") . ".html" so, the following lines will create an 'alias' or 'map' which will allow the user of vim to filter the current file using the key stroke sequence ',1' that is 1. In the lines below, the sequence is actually typed literally. -->> map ,1 :exec "!plaintext2html.sh " . expand("%:p") . " > " . expand("%:p:r") . ".html" map ,2 :exec "!linkdoc2html.sh " . expand("%:p") . " > " . expand("%:p:r") . ".html" map ,3 :exec "!diary2html.sh " . expand("%:p") . " > " . expand("%:p:r") . ".html" map ,4 :exec "!plaintext2pdf.sh " . expand("%:p") --<< You can type ':map' to see what maps are currently available. The line above should go into the /etc/vim/vimrc file or path\_vimrc on MS Windows. This convention of using comma initiated sequences for maps appears to be common to prevent the sequences from interfering with other Vi/Vim sequences. some 'vi' tricks, and the briefest of survival guides. yes 'vi' is the work of the devil. Install 'vim' for more powerful commands such as interactive batch processing of files. Vim also has a good set of help files, unlike vi. Or else use 'setedit' which is a MS DOS 'edit' style program. Or else use 'emacs' ...Also see the file /alexis-info/docs/important-tools.html for a description of unix-born text editors and why they seem annoying. Some people will comment that there are already on the Internet a very, very large number of vi and vim 'quick references', so why this one. The only justification is that I believe these commands are in order of importance, which is not usual. -->> please type... i to start inserting text. [esc] to stop inserting text :w to save the current file :q to exit from the current file. :q! to exit without saving. x to delete the character under the cursor dd to delete the current line u to undo the last change that you made . to repeat the last change that you made y10+ to put the current line and the next 10 into the 'buffer' (for copying and pasting) p insert the contents of the 'buffer' into the current file at the current cursor position. (ie 'paste') :set number to see line numbers for the file :set sw=2 to set the standard 'shift width' to 2 spaces >284G to shift all lines from the current line down to line 284, 2 places to the right (assuming that your shift width is set to 2 (see above) !}fmt to format all lines from the current line (which is the cursor position) down to the end of the paragraph (which is the first blank line). Formatting means doing a kind of 'word wrap' on the lines. This assumes that you have the external program fmt on your computer, which if you are using unix you almost certainly will, and if you are using Microsoft Windows you probably won't, but can get from somewhere like http://gnuWin32.sourceforge.net/ (url?) :set nonumber to not see line numbers for the file :1,$ s/woman/man/gic to change all instances of the word woman in the current file to the word man, ignoring the capitalisation of the word woman, and pausing for confirmation with the user whether to change each individual occurance. :viusage to see an incredibly terse, uncommunicative and essentially unhelpful list of vi commands :exusage to see the same style list for 'ex' commands (which are the commands that you type after the ':' character :!zless /usr/share/doc/nvi/vi.beginner.gz :!zless /usr/share/doc/nvi/vi.advanced.gz to see some not particulary good tutorials on vi usage. :new filename to edit another file in a new 'window'. control w control k move up one window control w control j moves down one window --<< MISCELANEOUS http://www.linux-mag.com/1999-11/joy_01.html An interview with Bill Joy, of sun microsystems, creator of vi Very good. A Vim thing called 'Exuberant Ctags' may be a way of automatically generating XML tags, for a kind of 'tag completion' function in Vim. please send comments or suggestions to: matthew@ella-associates.org or matth3wbishop@yahoo.com