Mercurial > hg > RemoteEditor > vim7
annotate runtime/doc/os_vms.txt @ 34:e170173ecb68 current-release
before ack base protocol.
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Wed, 26 Nov 2008 15:02:10 +0900 |
parents | 76efa0be13f1 |
children | c16898406ff2 |
rev | line source |
---|---|
34
e170173ecb68
before ack base protocol.
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
0
diff
changeset
|
1 *os_vms.txt* For Vim version 7.2. Last change: 2006 Nov 18 |
0 | 2 |
3 | |
4 VIM REFERENCE MANUAL | |
5 | |
6 | |
7 *VMS* *vms* | |
8 This file contains the particularities for the VMS version of Vim. | |
9 You can reach this information file by typing :help VMS in Vim command | |
10 prompt. | |
11 | |
12 1. Getting started |vms-started| | |
13 2. Download files |vms-download| | |
14 3. Compiling |vms-compiling| | |
15 4. Problems |vms-problems| | |
16 5. Deploy |vms-deploy| | |
17 6. Practical usage |vms-usage| | |
18 7. GUI mode questions |vms-gui| | |
19 8. Useful notes |vms-notes| | |
20 9. VMS related changes |vms-changes| | |
21 10. Authors |vms-authors| | |
22 | |
23 ============================================================================== | |
24 | |
25 1. Getting started *vms-started* | |
26 | |
27 Vim (Vi IMproved) is a vi-compatible text editor that runs on nearly every | |
28 operating system known to humanity. Now use Vim on OpenVMS too, in character | |
29 or X/Motif environment. It is fully featured and absolutely compatible with | |
30 Vim on other operating systems. | |
31 | |
32 ============================================================================== | |
33 | |
34 2. Download files *vms-download* | |
35 | |
36 You can download the Vim source code by ftp from the official Vim site: | |
37 ftp://ftp.vim.org/pub/vim/ | |
38 Or use one of the mirrors: | |
39 ftp://ftp.vim.org/pub/vim/MIRRORS | |
40 | |
41 You will need both the Unix and Extra archives to build vim.exe for VMS. | |
42 For using Vim's full power you will need the runtime files as well. | |
43 | |
44 You can download precompiled executables from: | |
45 http://www.polarhome.com/vim/ | |
46 ftp://ftp.polarhome.com/pub/vim/ | |
47 | |
48 To use the precompiled binary version, you need one of these archives: | |
49 | |
50 vim-XX-exe-ia64-gui.zip IA64 GUI/Motif executables | |
51 vim-XX-exe-ia64-gtk.zip IA64 GUI/GTK executables | |
52 vim-XX-exe-ia64-term.zip IA64 console executables | |
53 vim-XX-exe-axp-gui.zip Alpha GUI/Motif executables | |
54 vim-XX-exe-axp-gtk.zip Alpha GUI/GTK executables | |
55 vim-XX-exe-axp-term.zip Alpha console executables | |
56 vim-XX-exe-vax-gui.zip VAX GUI executables | |
57 vim-XX-exe-vax-term.zip VAX console executables | |
58 | |
59 and of course (optional) | |
60 vim-XX-runtime.zip runtime files | |
61 | |
62 The binary archives contain: vim.exe, ctags.exe, xxd.exe files. | |
63 | |
64 For GTK executables you will need GTKLIB that is available for | |
65 Alpha and IA64 platform. | |
66 | |
67 ============================================================================== | |
68 | |
69 3. Compiling *vms-compiling* | |
70 | |
71 See the file [.SRC]INSTALLVMS.TXT. | |
72 | |
73 ============================================================================== | |
74 | |
75 4. Problems *vms-problems* | |
76 | |
77 The code has been tested under Open VMS 6.2 - 8.2 on Alpha, VAX and IA64 | |
78 platforms with the DEC C compiler. It should work without bigger problems. | |
79 If your system does not have some include libraries you can tune up in | |
80 OS_VMS_CONF.H file. | |
81 | |
82 If you decided to build Vim with +perl, +python, etc. options, first you need | |
83 to download OpenVMS distributions of Perl and Python. Build and deploy the | |
84 libraries and change adequate lines in MAKE_VMS.MMS file. There should not be | |
85 a problem from Vim side. | |
86 | |
87 Also GTK, XPM library paths should be configured in MAKE_VMS.MMS | |
88 | |
89 Note: Under VAX it should work with the DEC C compiler without problems. The | |
90 VAX C compiler is not fully ANSI C compatible in pre-processor directives | |
91 semantics, therefore you have to use a converter program what will do the lion | |
92 part of the job. For detailed instructions read file INSTALLvms.txt | |
93 | |
94 MMS_VIM.EXE is build together with VIM.EXE, but for XD.EXE you should | |
95 change to subdirectory and build it separately. | |
96 | |
97 CTAGS is not part of the Vim source distribution anymore, however the OpenVMS | |
98 specific source might contain CTAGS source files as described above. | |
99 You can find more information about CTAGS on VMS at | |
100 http://www.polarhome.com/ctags/ | |
101 | |
102 Advanced users may try some acrobatics in FEATURE.H file also. | |
103 | |
104 It is possible to compile with +xfontset +xim options too, but then you have | |
105 to set up GUI fonts etc. correctly. See :help xim from Vim command prompt. | |
106 | |
107 You may want to use GUI with GTK icons, then you have to download and install | |
108 GTK for OpenVMS or at least runtime shareable images - LIBGTK from | |
109 polarhome.com | |
110 | |
111 For more advanced questions, please send your problem to Vim on VMS mailing | |
112 list <vim-vms@polarhome.com> | |
113 More about the vim-vms list can be found at: | |
114 http://www.polarhome.com/mailman/listinfo/vim-vms | |
115 | |
116 ============================================================================== | |
117 | |
118 5. Deploy *vms-deploy* | |
119 | |
120 Vim uses a special directory structure to hold the document and runtime files: | |
121 | |
122 vim (or wherever) | |
123 |- tmp | |
124 |- vim57 | |
125 |----- doc | |
126 |----- syntax | |
127 |- vim62 | |
128 |----- doc | |
129 |----- syntax | |
130 |- vim64 | |
131 |----- doc | |
132 |----- syntax | |
133 vimrc (system rc files) | |
134 gvimrc | |
135 | |
136 Use: > | |
137 | |
138 define/nolog VIM device:[path.vim] | |
139 define/nolog VIMRUNTIME device:[path.vim.vim60] | |
140 define/nolog TMP device:[path.tmp] | |
141 | |
142 to get vim.exe to find its document, filetype, and syntax files, and to | |
143 specify a directory where temporary files will be located. Copy the "runtime" | |
144 subdirectory of the vim distribution to vimruntime. | |
145 | |
146 Logicals $VIMRUNTIME and $TMP are optional. | |
147 | |
148 If $VIMRUNTIME is not set, Vim will guess and try to set up automatically. | |
149 Read more about it at :help runtime | |
150 | |
151 If $TMP is not set, you will not be able to use some functions as CTAGS, | |
152 XXD, printing etc. that use temporary directory for normal operation. | |
153 The $TMP directory should be readable and writable by the user(s). | |
154 The easiest way to set up $TMP is to define a logical: > | |
155 | |
156 define/nolog TMP SYS$SCRATCH | |
157 or as: > | |
158 define/nolog TMP SYS$LOGIN | |
159 | |
160 ============================================================================== | |
161 | |
162 6. Practical usage *vms-usage* | |
163 | |
164 Usually, you want to run just one version of Vim on your system, therefore | |
165 it is enough to dedicate one directory for Vim. | |
166 Copy the whole Vim runtime directory structure to the deployment position. | |
167 Add the following lines to your LOGIN.COM (in SYS$LOGIN directory). | |
168 Set up the logical $VIM as: > | |
169 | |
170 $ define VIM device:<path> | |
171 | |
172 Set up some symbols: > | |
173 | |
174 $ ! vi starts Vim in chr. mode. | |
175 $ vi*m :== mcr VIM:VIM.EXE | |
176 | |
177 $ !gvi starts Vim in GUI mode. | |
178 $ gv*im :== spawn/nowait mcr VIM:VIM.EXE -g | |
179 | |
180 Please, check the notes for customization and configuration of symbols. | |
181 | |
182 You may want to create .vimrc and .gvimrc files in your home directory | |
183 (SYS$LOGIN) to overwrite default settings. | |
184 | |
185 The easiest way is just rename example files. You may leave the menu file | |
186 (MENU.VIM) and files vimrc and gvimrc in the original $VIM directory. It will | |
187 be default setup for all users, and for users it is enough just to have their | |
188 own additions or resetting in their home directory in files .vimrc and .gvimrc. | |
189 It should work without problems. | |
190 | |
191 Note: Remember, system rc files (default for all users) don't have a leading | |
192 ".". So, system rc files are: > | |
193 | |
194 $VIM:vimrc | |
195 $VIM:gvimrc | |
196 $VIM:menu.vim | |
197 | |
198 and user customized rc files are: > | |
199 | |
200 sys$login:.vimrc | |
201 sys$login:.gvimrc | |
202 | |
203 You can check that everything is on the right place with the :version command. | |
204 | |
205 Example LOGIN.COM: > | |
206 | |
207 $ define/nolog VIM RF10:[UTIL.VIM] | |
208 $ vi*m :== mcr VIM:VIM.EXE | |
209 $ gv*im:== spawn/nowait/input=NLA0 mcr VIM:VIM.EXE -g -GEOMETRY 80x40 | |
210 $ set disp/create/node=192.168.5.223/trans=tcpip | |
211 | |
212 Note: This set-up should be enough, if you are working on standalone server or | |
213 clustered environment, but if you want to use Vim as internode editor in | |
214 DECNET environment, it will satisfy as well. | |
215 You just have to define the "whole" path: > | |
216 | |
217 $ define VIM "<server_name>[""user password""]::device:<path>" | |
218 $ vi*m :== "mcr VIM:VIM.EXE" | |
219 | |
220 as for example: > | |
221 | |
222 $ define VIM "PLUTO::RF10:[UTIL.VIM]" | |
223 $ define VIM "PLUTO""ZAY mypass""::RF10:[UTIL.VIM]" ! if passwd required | |
224 | |
225 You can also use the $VIMRUNTIME logical to point to the proper version of Vim | |
226 if you have installed more versions at the same time. If $VIMRUNTIME is not | |
227 defined Vim will borrow its value from the $VIM logical. You can find more | |
228 information about the $VIMRUNTIME logical by typing :help runtime as a Vim | |
229 command. | |
230 | |
231 System administrators might want to set up a system wide Vim installation, | |
232 then add to the SYS$STARTUP:SYLOGICALS.COM > | |
233 | |
234 $ define/nolog/sys VIM device:<path> | |
235 $ define/nolog/sys TMP SYS$SCRATCH | |
236 | |
237 and to the SYS$STARTUP:SYLOGIN.COM > | |
238 | |
239 $ vi*m :== mcr VIM:VIM.EXE | |
240 $ gv*im:== spawn/nowait/input=NLA0 mcr VIM:VIM.EXE -g -GEOMETRY 80x40 | |
241 | |
242 | |
243 It will set up a normal Vim work environment for every user on the system. | |
244 | |
245 IMPORTANT: Vim on OpenVMS (and on other case insensitive system) command line | |
246 parameters are assumed to be lowercase. In order to indicate that a command | |
247 line parameter is uppercase "/" sign must be used. | |
248 | |
249 Examples: | |
250 > | |
251 vim -R filename ! means: -r List swap files and exit | |
252 vim -/r filename ! means: -R Readonly mode (like "view") | |
253 vim -u <vimrc> ! means: -u Use <vimrc> instead of any .vimrc | |
254 vim -/u <gvimrc> ! means: -U Use <gvimrc> instead of any .gvimrc | |
255 | |
256 ============================================================================== | |
257 | |
258 7. GUI mode questions *vms-gui* | |
259 | |
260 OpenVMS is a real mainframe OS, therefore even if it has a GUI console, most | |
261 of the users do not use a native X/Window environment during normal operation. | |
262 It is not possible to start Vim in GUI mode "just like that". But anyhow it | |
263 is not too complicated either. | |
264 | |
265 First of all: you will need an executable that is built with the GUI enabled. | |
266 | |
267 Second: you need to have installed DECW/Motif on your VMS server, otherwise | |
268 you will get errors that some shareable libraries are missing. | |
269 | |
270 Third: If you choose to run Vim with extra features such as GUI/GTK then you | |
271 need a GTK installation too or at least a GTK runtime environment (LIBGTK | |
272 can be downloaded from http://www.polarhome.com/vim/). | |
273 | |
274 1) If you are working on the VMS X/Motif console: | |
275 Start Vim with the command: > | |
276 | |
277 $ mc device:<path>VIM.EXE -g | |
278 < | |
279 or type :gui as a command to the Vim command prompt. For more info :help | |
280 gui | |
281 | |
282 2) If you are working on some other X/Window environment like Unix or a remote | |
283 X VMS console. Set up display to your host with: > | |
284 | |
285 $ set disp/create/node=<your IP address>/trans=<transport-name> | |
286 < | |
287 and start Vim as in point 1. You can find more help in VMS documentation or | |
288 type: help set disp in VMS prompt. | |
289 Examples: > | |
290 | |
291 $ set disp/create/node=192.168.5.159 ! default trans is DECnet | |
292 $ set disp/create/node=192.168.5.159/trans=tcpip ! TCP/IP network | |
293 $ set disp/create/node=192.168.5.159/trans=local ! display on the same node | |
294 | |
295 Note: you should define just one of these. | |
296 For more information type $help set disp in VMS prompt. | |
297 | |
298 3) Another elegant solution is XDM if you have installed on OpenVMS box. | |
299 It is possible to work from XDM client as from GUI console. | |
300 | |
301 4) If you are working on MS-Windows or some other non X/Window environment | |
302 you need to set up one X server and run Vim as in point 2. | |
303 For MS-Windows there are available free X servers as MIX , Omni X etc., | |
304 as well as excellent commercial products as eXcursion or ReflectionX with | |
305 built-in DEC support. | |
306 | |
307 Please note, that executables without GUI are slightly faster during startup | |
308 then with enabled GUI in character mode. Therefore, if you do not use GUI | |
309 features, it is worth to choose non GUI executables. | |
310 | |
311 ============================================================================== | |
312 | |
313 8. Useful notes *vms-notes* | |
314 | |
315 8.1 backspace/delete | |
316 8.2 Filters | |
317 8.3 VMS file version numbers | |
318 8.4 Directory conversion | |
319 8.5 Remote host invocation | |
320 8.6 Terminal problems | |
321 8.7 Hex-editing and other external tools | |
322 8.8 Sourcing vimrc and gvimrc | |
323 8.9 Printing from Vim | |
324 8.10 Setting up the symbols | |
325 8.11 diff and other GNU programs | |
326 8.12 diff-mode | |
327 8.13 Allow '$' in C keywords | |
328 8.14 VIMTUTOR for beginners | |
329 | |
330 8.1 backspace/delete | |
331 | |
332 There are backspace/delete key inconsistencies with VMS. | |
333 :fixdel doesn't do the trick, but the solution is: > | |
334 | |
335 :inoremap ^? ^H " for terminal mode | |
336 :inoremap <Del> ^H " for gui mode | |
337 | |
338 Read more in ch: 8.6 (Terminal problems). | |
339 (Bruce Hunsaker <BNHunsaker@chq.byu.edu> Vim 5.3) | |
340 | |
341 | |
342 8.2 Filters | |
343 | |
344 Vim supports filters, i.e., if you have a sort program that can handle | |
345 input/output redirection like Unix (<infile >outfile), you could use > | |
346 | |
347 :map \s 0!'aqsort<CR> | |
348 | |
349 (Charles E. Campbell, Jr. <cec@gryphon.gsfc.nasa.gov> Vim 5.4) | |
350 | |
351 | |
352 8.3 VMS file version numbers | |
353 | |
354 Vim is saving files into a new file with the next higher file version | |
355 number, try these settings. > | |
356 | |
357 :set nobackup " does not create *.*_ backup files | |
358 :set nowritebackup " does not have any purpose on VMS. It's the | |
359 " default. | |
360 | |
361 Recovery is working perfect as well from the default swap file. | |
362 Read more with :help swapfile | |
363 | |
364 (Claude Marinier <ClaudeMarinier@xwavesolutions.com> Vim 5.5, Zoltan Arpadffy | |
365 Vim 5.6) | |
366 | |
367 | |
368 8.4 Directory conversion | |
369 | |
370 Vim will internally convert any unix-style paths and even mixed unix/VMS | |
371 paths into VMS style paths. Some typical conversions resemble: | |
372 | |
373 /abc/def/ghi -> abc:[def]ghi. | |
374 /abc/def/ghi.j -> abc:[def]ghi.j | |
375 /abc/def/ghi.j;2 -> abc:[def]ghi.j;2 | |
376 /abc/def/ghi/jkl/mno -> abc:[def.ghi.jkl]mno. | |
377 abc:[def.ghi]jkl/mno -> abc:[def.ghi.jkl]mno. | |
378 ./ -> current directory | |
379 ../ -> relative parent directory | |
380 [.def.ghi] -> relative child directory | |
381 ./def/ghi -> relative child directory | |
382 | |
383 Note: You may use <,> brackets as well (device:<path>file.ext;version) as | |
384 rf10:<user.zay.work>test.c;1 | |
385 | |
386 (David Elins <delins@foliage.com>, Jerome Lauret | |
387 <JLAURET@mail.chem.sunysb.edu> Vim 5.6 ) | |
388 | |
389 | |
390 8.5 Remote host invocation | |
391 | |
392 It is possible to use Vim as an internode editor. | |
393 1. Edit some file from remote node: > | |
394 | |
395 vi "<server>""username passwd""::<device>:<path><filename>;<version>" | |
396 | |
397 example: > | |
398 vi "pluto""zay passwd""::RF10:<USER.ZAY.WORK>TEST.C;1" | |
399 | |
400 Note: syntax is very important, otherwise VMS will recognize more parameters | |
401 instead of one (resulting with: file not found) | |
402 | |
403 2. Set up Vim as your internode editor. If Vim is not installed on your | |
404 host, just set up your IP address, the full Vim path including the server name | |
405 and run the command procedure below: > | |
406 | |
407 $ if (p1 .eqs. "") .OR. (p2 .eqs. "") then goto usage | |
408 $ set disp/create/node=<your_IP_here>/trans=tcpip | |
409 $ define "VIM "<vim_server>""''p1' ''p2'""::<device>:<vim_path>" | |
410 $ vi*m :== "mcr VIM:VIM.EXE" | |
411 $ gv*im :== "spawn/nowait mcr VIM:VIM.EXE -g" | |
412 $ goto end | |
413 $ usage: | |
414 $ write sys$output " Please enter username and password as a parameter." | |
415 $ write sys$output " Example: @SETVIM.COM username passwd" | |
416 $ end: | |
417 | |
418 Note: Never use it in a clustered environment (you do not need it), loading | |
419 could be very-very slow, but even faster then a local Emacs. :-) | |
420 | |
421 (Zoltan Arpadffy, Vim 5.6) | |
422 | |
423 | |
424 8.6 Terminal problems | |
425 | |
426 If your terminal name is not known to Vim and it is trying to find the default | |
427 one you will get the following message during start-up: | |
428 --- | |
429 Terminal entry not found in termcap | |
430 'unknown-terminal' not known. Available built-in terminals are: | |
431 builtin_gui | |
432 builtin_riscos | |
433 builtin_amiga | |
434 builtin_beos-ansi | |
435 builtin_ansi | |
436 builtin_vt320 | |
437 builtin_vt52 | |
438 builtin_pcansi | |
439 builtin_win32 | |
440 builtin_xterm | |
441 builtin_iris-ansi | |
442 builtin_debug | |
443 builtin_dumb | |
444 defaulting to 'vt320' | |
445 --- | |
446 The solution is to define default terminal name: > | |
447 | |
448 $ ! unknown terminal name. Let us use vt320 or ansi instead. | |
449 $ ! Note: it's case sensitive | |
450 $ define term "vt320" | |
451 | |
452 Terminals from VT100 to VT320 (as V300, VT220, VT200 ) do not need any extra | |
453 keyboard mappings. They should work perfect as they are, including arrows, | |
454 Ins, Del buttons etc., except Backspace in GUI mode. To solve it, add to | |
455 .gvimrc: > | |
456 | |
457 inoremap <Del> <BS> | |
458 | |
459 Vim will also recognize that they are fast terminals. | |
460 | |
461 If you have some annoying line jumping on the screen between windows add to | |
462 your .vimrc file: > | |
463 | |
464 set ttyfast " set fast terminal | |
465 | |
466 Note: if you're using Vim on remote host or through very slow connection, it's | |
467 recommended to avoid fast terminal option with: > | |
468 | |
469 set nottyfast " set terminal to slow mode | |
470 | |
471 (Zoltan Arpadffy, Vim 5.6) | |
472 | |
473 | |
474 8.7 Hex-editing and other external tools | |
475 | |
476 A very important difference between OpenVMS and other systems is that VMS uses | |
477 special commands to execute executables: > | |
478 | |
479 RUN <path>filename | |
480 MCR <path>filename <parameters> | |
481 | |
482 OpenVMS users always have to be aware that the Vim command :! "just" drop them | |
483 to DCL prompt. This feature is possible to use without any problem with all | |
484 DCL commands, but if we want to execute some program as XXD, CTAGS, JTAGS etc. | |
485 we're running into trouble if we follow the Vim documentation (see: help | |
486 xxd). | |
487 | |
488 Solution: Execute with the MC command and add the full path to the executable. | |
489 Example: Instead of :%!xxd command use: > | |
490 | |
491 :%!mc vim:xxd | |
492 | |
493 ... or in general: > | |
494 :!mc <path>filename <parameters> | |
495 | |
496 Note: You can use XXD and CTAGS from GUI menu. | |
497 | |
498 To customize ctags it is possible to define the logical $CTAGS with standard | |
499 parameters as: > | |
500 | |
501 define/nolog CTAGS "--totals -o sys$login:tags" | |
502 | |
503 For additional information, please read :help tagsearch and CTAGS | |
504 documentation at http://ctags.sourceforge.net/ctags.html. | |
505 | |
506 (Zoltan Arpadffy, Vim 5.6-70) | |
507 | |
508 | |
509 8.8 Sourcing vimrc and gvimrc | |
510 | |
511 If you want to use your .vimrc and .gvimrc from other platforms (e.g. Windows) | |
512 you can get in trouble if you ftp that file(s): VMS has different end-of-line | |
513 indication. | |
514 The symptom is that Vim is not sourcing your .vimrc/.gvimrc, even if you say: | |
515 > | |
516 :so sys$login:.vimrc | |
517 | |
518 One trick is to compress (e.g. zip) the files on the other platform and | |
519 uncompress it on VMS; if you have the same symptom, try to create the files | |
520 with copy-paste (for this you need both op. systems reachable from one | |
521 machine, e.g. an Xterm on Windows or telnet to Windows from VMS). | |
522 | |
523 (Sandor Kopanyi, <sandor.kopanyi@mailbox.hu> Vim 6.0a) | |
524 | |
525 | |
526 8.9 Printing from Vim | |
527 | |
528 To be able to print from Vim (running in GUI mode) under VMS you have to set | |
529 up $TMP logical which should point to some temporary directory and logical | |
530 SYS$PRINT to your default print queue. | |
531 Example: > | |
532 | |
533 $define SYS$PRINT HP5ANSI | |
534 | |
535 You can print out whole buffer or just the marked area. | |
536 More info under :help hardcopy | |
537 | |
538 (Zoltan Arpadffy, Vim 6.0c) | |
539 | |
540 | |
541 8.10 Setting up the symbols | |
542 | |
543 When I use GVIM this way and press CTRL-Y in the parent terminal, gvim exits. | |
544 I now use a different symbol that seems to work OK and fixes the problem. | |
545 I suggest this instead: > | |
546 | |
547 $ GV*IM:==SPAWN/NOWAIT/INPUT=NLA0: MCR VIM:VIM.EXE -G -GEOMETRY 80X40 | |
548 | |
549 The /INPUT=NLA0: separates the standard input of the gvim process from the | |
550 parent terminal, to block signals from the parent window. | |
551 Without the -GEOMETRY, the GVIM window size will be minimal and the menu | |
552 will be confused after a window-resize. | |
553 | |
554 (Carlo Mekenkamp, Coen Engelbarts, Vim 6.0ac) | |
555 | |
556 | |
557 8.11 diff and other GNU programs | |
558 | |
559 From 6.0 diff functionality has been implemented, but OpenVMS does not use | |
560 GNU/Unix like diff therefore built in diff does not work. | |
561 There is a simple solution to solve this anomaly. Install a Unix like diff | |
562 and Vim will work perfect in diff mode too. You just have to redefine your | |
563 diff program as: > | |
564 | |
565 define /nolog diff <GNU_PATH>diff.exe | |
566 | |
567 Another, more sophisticated solution is described below (8.12 diff-mode) | |
568 There are some other programs as patch, make etc that may cause same problems. | |
569 At www.polarhome.com is possible to download an GNU package for Alpha and VAX | |
570 boxes that is meant to solve GNU problems on OpenVMS. | |
571 ( Zoltan Arpadffy, Vim 6.1) | |
572 | |
573 | |
574 8.12 diff-mode | |
575 | |
576 Vim 6.0 and higher supports vim diff-mode (See |new-diff-mode|, |diff-mode| | |
577 and |08.7|). This uses the external program 'diff' and expects a Unix-like | |
578 output format from diff. The standard VMS diff has a different output | |
579 format. To use vim on VMS in diff-mode, you need to: | |
580 1 Install a Unix-like diff program, e.g. GNU diff | |
581 2 Tell vim to use the Unix-like diff for diff-mode. | |
582 | |
583 You can download GNU diff from the VIM-VMS website, it is one of the GNU | |
584 tools in http://www.polarhome.com/vim/files/gnu_tools.zip. I suggest to | |
585 unpack it in a separate directory "GNU" and create a logical GNU: that | |
586 points to that directory, e.g: > | |
587 | |
588 DEFINE GNU <DISK>:[<DIRECTORY>.BIN.GNU] | |
589 | |
590 You may also want to define a symbol GDIFF, to use the GNU diff from the DCL | |
591 prompt: > | |
592 | |
593 GDIFF :== $GNU:DIFF.EXE | |
594 | |
595 Now you need to tell vim to use the new diff program. Take the example | |
596 settings from |diff-diffexpr| and change the call to the external diff | |
597 program to the new diff on VMS. Add this to your .vimrc file: > | |
598 | |
599 " Set up vimdiff options | |
600 if v:version >= 600 | |
601 " Use GNU diff on VMS | |
602 set diffexpr=MyDiff() | |
603 function MyDiff() | |
604 let opt = "" | |
605 if &diffopt =~ "icase" | |
606 let opt = opt . "-i " | |
607 endif | |
608 if &diffopt =~ "iwhite" | |
609 let opt = opt . "-b " | |
610 endif | |
611 silent execute "!mc GNU:diff.exe -a " . opt . v:fname_in . " " . v:fname_new . | |
612 \ " > " . v:fname_out | |
613 endfunction | |
614 endif | |
615 | |
616 You can now use vim in diff-mode, e.g. to compare two files in read-only | |
617 mode: > | |
618 | |
619 $ VIM -D/R <FILE1> <FILE2> | |
620 | |
621 You can also define new symbols for vimdiff, e.g.: > | |
622 | |
623 $ VIMDIFF :== 'VIM' -D/R | |
624 $ GVIMDIFF :== 'GVIM' -D/R | |
625 | |
626 You can now compare files in 4 ways: > | |
627 | |
628 1. VMS diff: $ DIFF <FILE1> <FILE2> | |
629 2. GNU diff: $ GDIFF <FILE1> <FILE2> | |
630 3. VIM diff: $ VIMDIFF <FILE1> <FILE2> | |
631 4. GVIM diff: $ GVIMDIFF <FILE1> <FILE2> | |
632 | |
633 ( Coen Engelbarts, Vim 6.1) | |
634 | |
635 | |
636 8.13 Allow '$' in C keywords | |
637 | |
638 DEC C uses many identifiers with '$' in them. This is not allowed in ANSI C, | |
639 and vim recognises the '$' as the end of the identifier. You can change this | |
640 with the |iskeyword|command. | |
641 Add this command to your .vimrc file: > | |
642 | |
643 autocmd FileType c,cpp,cs set iskeyword+=$ | |
644 | |
645 You can also create the file(s) $VIM/FTPLUGIN/C.VIM (and/or CPP.VIM and | |
646 CS.VIM) and add this command: > | |
647 | |
648 set iskeyword+=$ | |
649 | |
650 Now word-based commands, e.g. the '*'-search-command and the CTRL-] | |
651 tag-lookup, work on the whole identifier. (Ctags on VMS also supports '$' in | |
652 C keywords since ctags version 5.1.) | |
653 | |
654 ( Coen Engelbarts, Vim 6.1) | |
655 | |
656 8.14 VIMTUTOR for beginners | |
657 | |
658 It exits VIMTUTOR.COM DCL script that can help Vim beginners to learn/make | |
659 first steps with Vim on OpenVMS. Depending of binary distribution you may | |
660 start it with: > | |
661 | |
662 @vim:vimtutor | |
663 | |
664 (Thomas.R.Wyant III, Vim 6.1) | |
665 | |
666 ============================================================================== | |
667 | |
668 9. VMS related changes *vms-changes* | |
669 | |
670 Version 7 | |
671 - Improved low level char input (affects just console mode) | |
672 | |
673 Version 6.4 (2005 Oct 15) | |
674 - GTKLIB and Vim build on IA64 | |
675 - colors in terminal mode | |
676 - syntax highlighting in terminal mode | |
677 - write problem fixed (extra CR) | |
678 - ESC and ESC sequence recognition in terminal mode | |
679 - make file changed to support new MMS version | |
680 - env variable expansion in path corrected | |
681 - printing problems corrected | |
682 - help text added for case insensitive arguments | |
683 | |
684 Version 6.3 (2004 May 10) | |
685 - Improved vms_read function | |
686 - CTAGS v5.5.4 included | |
687 - Documentation corrected and updated | |
688 | |
689 Version 6.2 (2003 May 7) | |
690 - Corrected VMS system call results | |
691 - Low level character input is rewritten | |
692 - Correction in tag and quickfix handling | |
693 - First GTK build | |
694 - Make file changes | |
695 - GTK feature added | |
696 - Define for OLD_VMS | |
697 - OpenVMS version 6.2 or older | |
698 - Documentation updated with GTK features | |
699 - CTAGS v5.5 included | |
700 - VMS VIM tutor created | |
701 | |
702 Version 6.1 (2002 Mar 25) | |
703 - TCL init_tcl() problem fixed | |
704 - CTAGS v5.4 included | |
705 - GNU tools binaries for OpenVMS | |
706 - Make file changes | |
707 - PERL, PYTHON and TCL support improved | |
708 - InstallVMS.txt has a detailed description HOWTO build | |
709 - VMS/Unix file handling rewritten | |
710 - Minor casting and bug fixes | |
711 | |
712 Version 6.0 (2001 Sep 28) | |
713 - Unix and VMS code has been merged | |
714 - separated "really" VMS related code | |
715 - included all possible Unix functionality | |
716 - simplified or deleted the configuration files | |
717 - makefile MAKE_VMS.MMS reviewed | |
718 - menu changes (fixed printing, CTAGS and XXD usage) | |
719 - fixed variable RMS record format handling anomaly | |
720 - corrected syntax, ftplugin etc files load | |
721 - changed expand_wildcards and expandpath functions to work more general | |
722 - created OS_VMS_FILTER.COM - DECC->VAXC pre-processor directive convert | |
723 script. | |
724 - Improved code's VAXC and new DECC compilers compatibility | |
725 - changed quickfix parameters: | |
726 - errormessage format to suite DECC | |
727 - search, make and other commands to suite VMS system | |
728 - updated and renamed MMS make files for Vim and CTAGS. | |
729 - CTAGS has been removed from source distribution of Vim but it will remain | |
730 in OpenVMS binary distributions. | |
731 - simplified build/configuration procedure | |
732 - created INSTALLvms.txt - detailed compiling instructions under VMS. | |
733 - updated test scripts. | |
734 | |
735 Version 5.8 (2001 Jun 1) | |
736 - OS_VMS.TXT updated with new features. | |
737 - other minor fixes. | |
738 - documentation updated | |
739 - this version had been tested much more than any other OpenVMS version | |
740 earlier | |
741 | |
742 Version 5.7 (2000 Jun 24) | |
743 - New CTAGS v5.0 in distribution | |
744 - Documentation updated | |
745 | |
746 Version 5.6 (2000 Jan 17) | |
747 - VMS filename related changes: | |
748 - version handling (open everything, save to new version) | |
749 - correct file extension matching for syntax (version problem) | |
750 - handle <,> characters and passwords in directory definition | |
751 - handle internode/remote invocation and editing with passwords | |
752 - OpenVMS files will be treated case insensitive from now | |
753 - corrected response of expand("%:.") etc path related functions | |
754 (in one word: VMS directory handling internally) | |
755 - version command | |
756 - corrected (+,-) information data | |
757 - added compiler and OS version | |
758 - added user and host information | |
759 - resolving $VIM and $VIMRUNTIME logicals | |
760 - VMS port is in MAX_FEAT (maximum features) club with Unix, Win32 and OS/2. | |
761 - enabled farsi, rightleft etc. features | |
762 - undo level raised up to 1000 | |
763 - Updated OS_VMS.MMS file. | |
764 - maximum features ON is default | |
765 - Vim is compilable with +perl, +python and +tcl features. | |
766 - improved MMK compatibility | |
767 - Created MAKEFILE_VMS.MMS, makefile for testing Vim during development. | |
768 - Defined DEC terminal VT320 | |
769 - compatibility for VT3*0, VT2*0 and VT1*0 - ANSI terminals | |
770 backwards, but not VT340 and newer with colour capability. | |
771 - VT320 is default terminal for OpenVMS | |
772 - these new terminals are also fast ttys (default for OpenVMS). | |
773 - allowed dec_mouse ttym | |
774 - Updated files vimrc and gvimrc with VMS specific suggestions. | |
775 - OS_VMS.TXT updated with new features. | |
776 | |
777 Version 5.5 (1999 Dec 3) | |
778 - Popup menu line crash corrected. | |
779 - Handle full file names with version numbers. | |
780 - Directory handling (CD command etc.) | |
781 - Corrected file name conversion VMS to Unix and v.v. | |
782 - Correct response of expand wildcards | |
783 - Recovery is working from this version under VMS as well. | |
784 - Improved terminal and signal handing. | |
785 - Improved OS_VMS.TXT | |
786 | |
787 Version 5.4 (1999 Sep 9) | |
788 - Cut and paste mismatch corrected. | |
789 - Motif directories during open and save are corrected. | |
790 | |
791 Version 5.3 (1998 Oct 12) | |
792 - Minor changes in the code | |
793 - Standard distribution with +GUI option | |
794 | |
795 Version 5.1 (1998 Apr 21) | |
796 - Syntax and DEC C changes in the code | |
797 - Fixing problems with the /doc subdirectory | |
798 - Improve OS_VMS.MMS | |
799 | |
800 Version 4.5 (1996 Dec 16) | |
801 - First VMS port by Henk Elbers <henk@xs4all.nl> | |
802 | |
803 ============================================================================== | |
804 | |
805 10. Authors *vms-authors* | |
806 | |
807 OpenVMS documentation and executables are maintained by: | |
808 Zoltan Arpadffy <arpadffy@polarhome.com> | |
809 | |
810 This document uses parts and remarks from earlier authors and contributors | |
811 of OS_VMS.TXT: | |
812 Charles E. Campbell, Jr. <cec@gryphon.gsfc.nasa.gov> | |
813 Bruce Hunsaker <BNHunsaker@chq.byu.edu> | |
814 Sandor Kopanyi <sandor.kopanyi@mailbox.hu> | |
815 | |
816 vim:tw=78:ts=8:ft=help:norl: |