|
Karsten Hopp |
c85d93 |
To: vim-dev@vim.org
|
|
Karsten Hopp |
c85d93 |
Subject: Patch 7.2.031
|
|
Karsten Hopp |
c85d93 |
Fcc: outbox
|
|
Karsten Hopp |
c85d93 |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
c85d93 |
Mime-Version: 1.0
|
|
Karsten Hopp |
c85d93 |
Content-Type: text/plain; charset=ISO-8859-1
|
|
Karsten Hopp |
c85d93 |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
c85d93 |
------------
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
Patch 7.2.031
|
|
Karsten Hopp |
c85d93 |
Problem: Information in the viminfo file about previously edited files is
|
|
Karsten Hopp |
c85d93 |
not available to the user. There is no way to get a complete list
|
|
Karsten Hopp |
c85d93 |
of files edited in previous Vim sessions.
|
|
Karsten Hopp |
c85d93 |
Solution: Add v:oldfiles and fill it with the list of old file names when
|
|
Karsten Hopp |
c85d93 |
first reading the viminfo file. Add the ":oldfiles" command,
|
|
Karsten Hopp |
c85d93 |
":browse oldfiles" and the "#<123" special file name. Increase
|
|
Karsten Hopp |
c85d93 |
the default value for 'viminfo' from '20 to '100.
|
|
Karsten Hopp |
c85d93 |
Files: runtime/doc/cmdline.txt, runtime/doc/eval.txt,
|
|
Karsten Hopp |
c85d93 |
runtime/doc/starting.txt, runtime/doc/usr_21.txt, src/eval.c,
|
|
Karsten Hopp |
c85d93 |
src/ex_cmds.c, src/ex_cmds.h, src/ex_docmd.c, src/feature.h,
|
|
Karsten Hopp |
c85d93 |
src/fileio.c, src/main.c, src/mark.c, src/misc1.c,
|
|
Karsten Hopp |
c85d93 |
src/proto/eval.pro, src/proto/ex_cmds.pro, src/proto/mark.pro,
|
|
Karsten Hopp |
c85d93 |
src/option.c, src/structs.h, src/vim.h
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/runtime/doc/cmdline.txt Sat Aug 9 19:36:46 2008
|
|
Karsten Hopp |
c85d93 |
--- runtime/doc/cmdline.txt Thu Sep 18 22:55:27 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1,4 ****
|
|
Karsten Hopp |
c85d93 |
! *cmdline.txt* For Vim version 7.2. Last change: 2008 Jul 29
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
VIM REFERENCE MANUAL by Bram Moolenaar
|
|
Karsten Hopp |
c85d93 |
--- 1,4 ----
|
|
Karsten Hopp |
c85d93 |
! *cmdline.txt* For Vim version 7.2. Last change: 2008 Sep 18
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
VIM REFERENCE MANUAL by Bram Moolenaar
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 157,162 ****
|
|
Karsten Hopp |
c85d93 |
--- 157,167 ----
|
|
Karsten Hopp |
c85d93 |
(doesn't work at the expression prompt; some
|
|
Karsten Hopp |
c85d93 |
things such as changing the buffer or current
|
|
Karsten Hopp |
c85d93 |
window are not allowed to avoid side effects)
|
|
Karsten Hopp |
c85d93 |
+ When the result is a |List| the items are used
|
|
Karsten Hopp |
c85d93 |
+ as lines. They can have line breaks inside
|
|
Karsten Hopp |
c85d93 |
+ too.
|
|
Karsten Hopp |
c85d93 |
+ When the result is a Float it's automatically
|
|
Karsten Hopp |
c85d93 |
+ converted to a String.
|
|
Karsten Hopp |
c85d93 |
See |registers| about registers. {not in Vi}
|
|
Karsten Hopp |
c85d93 |
Implementation detail: When using the |expression| register
|
|
Karsten Hopp |
c85d93 |
and invoking setcmdpos(), this sets the position before
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 730,748 ****
|
|
Karsten Hopp |
c85d93 |
In Ex commands, at places where a file name can be used, the following
|
|
Karsten Hopp |
c85d93 |
characters have a special meaning. These can also be used in the expression
|
|
Karsten Hopp |
c85d93 |
function expand() |expand()|.
|
|
Karsten Hopp |
c85d93 |
! % is replaced with the current file name *:_%*
|
|
Karsten Hopp |
c85d93 |
! # is replaced with the alternate file name *:_#*
|
|
Karsten Hopp |
c85d93 |
#n (where n is a number) is replaced with the file name of
|
|
Karsten Hopp |
c85d93 |
! buffer n. "#0" is the same as "#"
|
|
Karsten Hopp |
c85d93 |
! ## is replaced with all names in the argument list *:_##*
|
|
Karsten Hopp |
c85d93 |
concatenated, separated by spaces. Each space in a name
|
|
Karsten Hopp |
c85d93 |
is preceded with a backslash.
|
|
Karsten Hopp |
c85d93 |
! Note that these give the file name as it was typed. If an absolute path is
|
|
Karsten Hopp |
c85d93 |
! needed (when using the file name from a different directory), you need to add
|
|
Karsten Hopp |
c85d93 |
! ":p". See |filename-modifiers|.
|
|
Karsten Hopp |
c85d93 |
Note that backslashes are inserted before spaces, so that the command will
|
|
Karsten Hopp |
c85d93 |
correctly interpret the file name. But this doesn't happen for shell
|
|
Karsten Hopp |
c85d93 |
! commands. For those you probably have to use quotes: >
|
|
Karsten Hopp |
c85d93 |
:!ls "%"
|
|
Karsten Hopp |
c85d93 |
:r !spell "%"
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
--- 735,763 ----
|
|
Karsten Hopp |
c85d93 |
In Ex commands, at places where a file name can be used, the following
|
|
Karsten Hopp |
c85d93 |
characters have a special meaning. These can also be used in the expression
|
|
Karsten Hopp |
c85d93 |
function expand() |expand()|.
|
|
Karsten Hopp |
c85d93 |
! % Is replaced with the current file name. *:_%* *c_%*
|
|
Karsten Hopp |
c85d93 |
! # Is replaced with the alternate file name. *:_#* *c_#*
|
|
Karsten Hopp |
c85d93 |
#n (where n is a number) is replaced with the file name of
|
|
Karsten Hopp |
c85d93 |
! buffer n. "#0" is the same as "#".
|
|
Karsten Hopp |
c85d93 |
! ## Is replaced with all names in the argument list *:_##* *c_##*
|
|
Karsten Hopp |
c85d93 |
concatenated, separated by spaces. Each space in a name
|
|
Karsten Hopp |
c85d93 |
is preceded with a backslash.
|
|
Karsten Hopp |
c85d93 |
! #<n (where n is a number > 0) is replaced with old *:_#<* *c_#<*
|
|
Karsten Hopp |
c85d93 |
! file name n. See |:oldfiles| or |v:oldfiles| to get the
|
|
Karsten Hopp |
c85d93 |
! number. *E809*
|
|
Karsten Hopp |
c85d93 |
! {only when compiled with the +eval and +viminfo features}
|
|
Karsten Hopp |
c85d93 |
!
|
|
Karsten Hopp |
c85d93 |
! Note that these, except "#
|
|
Karsten Hopp |
c85d93 |
! absolute path is needed (when using the file name from a different directory),
|
|
Karsten Hopp |
c85d93 |
! you need to add ":p". See |filename-modifiers|.
|
|
Karsten Hopp |
c85d93 |
!
|
|
Karsten Hopp |
c85d93 |
! The "#
|
|
Karsten Hopp |
c85d93 |
! below your home directory.
|
|
Karsten Hopp |
c85d93 |
!
|
|
Karsten Hopp |
c85d93 |
Note that backslashes are inserted before spaces, so that the command will
|
|
Karsten Hopp |
c85d93 |
correctly interpret the file name. But this doesn't happen for shell
|
|
Karsten Hopp |
c85d93 |
! commands. For those you probably have to use quotes (this fails for files
|
|
Karsten Hopp |
c85d93 |
! that contain a quote and wildcards): >
|
|
Karsten Hopp |
c85d93 |
:!ls "%"
|
|
Karsten Hopp |
c85d93 |
:r !spell "%"
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/runtime/doc/eval.txt Sat Aug 9 19:36:47 2008
|
|
Karsten Hopp |
c85d93 |
--- runtime/doc/eval.txt Sun Nov 2 14:25:38 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1,4 ****
|
|
Karsten Hopp |
c85d93 |
! *eval.txt* For Vim version 7.2. Last change: 2008 Aug 09
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
VIM REFERENCE MANUAL by Bram Moolenaar
|
|
Karsten Hopp |
c85d93 |
--- 1,4 ----
|
|
Karsten Hopp |
c85d93 |
! *eval.txt* For Vim version 7.2. Last change: 2008 Nov 02
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
VIM REFERENCE MANUAL by Bram Moolenaar
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1484,1489 ****
|
|
Karsten Hopp |
c85d93 |
--- 1484,1500 ----
|
|
Karsten Hopp |
c85d93 |
This is the screen column number, like with |virtcol()|. The
|
|
Karsten Hopp |
c85d93 |
value is zero when there was no mouse button click.
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
+ *v:oldfiles* *oldfiles-variable*
|
|
Karsten Hopp |
c85d93 |
+ v:oldfiles List of file names that is loaded from the |viminfo| file on
|
|
Karsten Hopp |
c85d93 |
+ startup. These are the files that Vim remembers marks for.
|
|
Karsten Hopp |
c85d93 |
+ The length of the List is limited by the ' argument of the
|
|
Karsten Hopp |
c85d93 |
+ 'viminfo' option (default is 100).
|
|
Karsten Hopp |
c85d93 |
+ Also see |:oldfiles| and |c_#<|.
|
|
Karsten Hopp |
c85d93 |
+ The List can be modified, but this has no effect on what is
|
|
Karsten Hopp |
c85d93 |
+ stored in the |viminfo| file later. If you use values other
|
|
Karsten Hopp |
c85d93 |
+ than String this will cause trouble.
|
|
Karsten Hopp |
c85d93 |
+ {only when compiled with the +viminfo feature}
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
*v:operator* *operator-variable*
|
|
Karsten Hopp |
c85d93 |
v:operator The last operator given in Normal mode. This is a single
|
|
Karsten Hopp |
c85d93 |
character except for commands starting with <g> or <z>,
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/runtime/doc/starting.txt Sat Aug 9 19:36:52 2008
|
|
Karsten Hopp |
c85d93 |
--- runtime/doc/starting.txt Sun Nov 9 12:12:19 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1,4 ****
|
|
Karsten Hopp |
c85d93 |
! *starting.txt* For Vim version 7.2. Last change: 2008 Jun 21
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
VIM REFERENCE MANUAL by Bram Moolenaar
|
|
Karsten Hopp |
c85d93 |
--- 1,4 ----
|
|
Karsten Hopp |
c85d93 |
! *starting.txt* For Vim version 7.2. Last change: 2008 Nov 09
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
VIM REFERENCE MANUAL by Bram Moolenaar
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1337,1344 ****
|
|
Karsten Hopp |
c85d93 |
*viminfo-read*
|
|
Karsten Hopp |
c85d93 |
When Vim is started and the 'viminfo' option is non-empty, the contents of
|
|
Karsten Hopp |
c85d93 |
the viminfo file are read and the info can be used in the appropriate places.
|
|
Karsten Hopp |
c85d93 |
! The marks are not read in at startup (but file marks are). See
|
|
Karsten Hopp |
c85d93 |
! |initialization| for how to set the 'viminfo' option upon startup.
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
*viminfo-write*
|
|
Karsten Hopp |
c85d93 |
When Vim exits and 'viminfo' is non-empty, the info is stored in the viminfo
|
|
Karsten Hopp |
c85d93 |
--- 1335,1343 ----
|
|
Karsten Hopp |
c85d93 |
*viminfo-read*
|
|
Karsten Hopp |
c85d93 |
When Vim is started and the 'viminfo' option is non-empty, the contents of
|
|
Karsten Hopp |
c85d93 |
the viminfo file are read and the info can be used in the appropriate places.
|
|
Karsten Hopp |
c85d93 |
! The |v:oldfiles| variable is filled. The marks are not read in at startup
|
|
Karsten Hopp |
c85d93 |
! (but file marks are). See |initialization| for how to set the 'viminfo'
|
|
Karsten Hopp |
c85d93 |
! option upon startup.
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
*viminfo-write*
|
|
Karsten Hopp |
c85d93 |
When Vim exits and 'viminfo' is non-empty, the info is stored in the viminfo
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1372,1377 ****
|
|
Karsten Hopp |
c85d93 |
--- 1371,1378 ----
|
|
Karsten Hopp |
c85d93 |
that start with any string given with the "r" flag in 'viminfo'. This can be
|
|
Karsten Hopp |
c85d93 |
used to avoid saving marks for files on removable media (for MS-DOS you would
|
|
Karsten Hopp |
c85d93 |
use "ra:,rb:", for Amiga "rdf0:,rdf1:,rdf2:").
|
|
Karsten Hopp |
c85d93 |
+ The |v:oldfiles| variable is filled with the file names that the viminfo file
|
|
Karsten Hopp |
c85d93 |
+ has marks for.
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
*viminfo-file-marks*
|
|
Karsten Hopp |
c85d93 |
Uppercase marks ('A to 'Z) are stored when writing the viminfo file. The
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1463,1470 ****
|
|
Karsten Hopp |
c85d93 |
*:rv* *:rviminfo* *E195*
|
|
Karsten Hopp |
c85d93 |
:rv[iminfo][!] [file] Read from viminfo file [file] (default: see above).
|
|
Karsten Hopp |
c85d93 |
If [!] is given, then any information that is
|
|
Karsten Hopp |
c85d93 |
! already set (registers, marks, etc.) will be
|
|
Karsten Hopp |
c85d93 |
! overwritten. {not in Vi}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
*:wv* *:wviminfo* *E137* *E138* *E574*
|
|
Karsten Hopp |
c85d93 |
:wv[iminfo][!] [file] Write to viminfo file [file] (default: see above).
|
|
Karsten Hopp |
c85d93 |
--- 1464,1471 ----
|
|
Karsten Hopp |
c85d93 |
*:rv* *:rviminfo* *E195*
|
|
Karsten Hopp |
c85d93 |
:rv[iminfo][!] [file] Read from viminfo file [file] (default: see above).
|
|
Karsten Hopp |
c85d93 |
If [!] is given, then any information that is
|
|
Karsten Hopp |
c85d93 |
! already set (registers, marks, |v:oldfiles|, etc.)
|
|
Karsten Hopp |
c85d93 |
! will be overwritten {not in Vi}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
*:wv* *:wviminfo* *E137* *E138* *E574*
|
|
Karsten Hopp |
c85d93 |
:wv[iminfo][!] [file] Write to viminfo file [file] (default: see above).
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1479,1482 ****
|
|
Karsten Hopp |
c85d93 |
--- 1480,1499 ----
|
|
Karsten Hopp |
c85d93 |
the .viminfo file.
|
|
Karsten Hopp |
c85d93 |
{not in Vi}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
+ *:ol* *:oldfiles*
|
|
Karsten Hopp |
c85d93 |
+ :ol[dfiles] List the files that have marks stored in the viminfo
|
|
Karsten Hopp |
c85d93 |
+ file. This list is read on startup and only changes
|
|
Karsten Hopp |
c85d93 |
+ afterwards with ":rviminfo!". Also see |v:oldfiles|.
|
|
Karsten Hopp |
c85d93 |
+ The number can be used with |c_#<|.
|
|
Karsten Hopp |
c85d93 |
+ {not in Vi, only when compiled with the +eval feature}
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ :bro[wse] ol[dfiles][!]
|
|
Karsten Hopp |
c85d93 |
+ List file names as with |:oldfiles|, and then prompt
|
|
Karsten Hopp |
c85d93 |
+ for a number. When the number is valid that file from
|
|
Karsten Hopp |
c85d93 |
+ the list is edited.
|
|
Karsten Hopp |
c85d93 |
+ If you get the |press-enter| prompt you can press "q"
|
|
Karsten Hopp |
c85d93 |
+ and still get the prompt to enter a file number.
|
|
Karsten Hopp |
c85d93 |
+ Use ! to abondon a modified buffer. |abandon|
|
|
Karsten Hopp |
c85d93 |
+ {not when compiled with tiny or small features}
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
vim:tw=78:ts=8:ft=help:norl:
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/runtime/doc/usr_21.txt Sat Aug 9 19:36:53 2008
|
|
Karsten Hopp |
c85d93 |
--- runtime/doc/usr_21.txt Sun Nov 9 12:14:10 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1,4 ****
|
|
Karsten Hopp |
c85d93 |
! *usr_21.txt* For Vim version 7.2. Last change: 2007 May 01
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
VIM USER MANUAL - by Bram Moolenaar
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
--- 1,4 ----
|
|
Karsten Hopp |
c85d93 |
! *usr_21.txt* For Vim version 7.2. Last change: 2008 Nov 09
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
VIM USER MANUAL - by Bram Moolenaar
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 153,159 ****
|
|
Karsten Hopp |
c85d93 |
to be lost. Each item can be remembered only once.
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
! GETTING BACK TO WHERE YOU WERE
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
You are halfway editing a file and it's time to leave for holidays. You exit
|
|
Karsten Hopp |
c85d93 |
Vim and go enjoy yourselves, forgetting all about your work. After a couple
|
|
Karsten Hopp |
c85d93 |
--- 153,159 ----
|
|
Karsten Hopp |
c85d93 |
to be lost. Each item can be remembered only once.
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
! GETTING BACK TO WHERE YOU STOPPED VIM
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
You are halfway editing a file and it's time to leave for holidays. You exit
|
|
Karsten Hopp |
c85d93 |
Vim and go enjoy yourselves, forgetting all about your work. After a couple
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 168,173 ****
|
|
Karsten Hopp |
c85d93 |
--- 168,215 ----
|
|
Karsten Hopp |
c85d93 |
The |:marks| command is useful to find out where '0 to '9 will take you.
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
+ GETTING BACK TO SOME FILE
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ If you want to go back to a file that you edited recently, but not when
|
|
Karsten Hopp |
c85d93 |
+ exiting Vim, there is a slightly more complicated way. You can see a list of
|
|
Karsten Hopp |
c85d93 |
+ files by typing the command: >
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ :oldfiles
|
|
Karsten Hopp |
c85d93 |
+ < 1: ~/.viminfo ~
|
|
Karsten Hopp |
c85d93 |
+ 2: ~/text/resume.txt ~
|
|
Karsten Hopp |
c85d93 |
+ 3: /tmp/draft ~
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ Now you would like to edit the second file, which is in the list preceded by
|
|
Karsten Hopp |
c85d93 |
+ "2:". You type: >
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ :e #<2
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ Instead of ":e" you can use any command that has a file name argument, the
|
|
Karsten Hopp |
c85d93 |
+ "#<2" item works in the same place as "%" (current file name) and "#"
|
|
Karsten Hopp |
c85d93 |
+ (alternate file name). So you can also split the window to edit the third
|
|
Karsten Hopp |
c85d93 |
+ file: >
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ :split #<3
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ That #<123 thing is a bit complicated when you just want to edit a file.
|
|
Karsten Hopp |
c85d93 |
+ Fortunately there is a simpler way: >
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ :browse oldfiles
|
|
Karsten Hopp |
c85d93 |
+ < 1: ~/.viminfo ~
|
|
Karsten Hopp |
c85d93 |
+ 2: ~/text/resume.txt ~
|
|
Karsten Hopp |
c85d93 |
+ 3: /tmp/draft ~
|
|
Karsten Hopp |
c85d93 |
+ -- More --
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ You get the same list of files as with |:oldfiles|. If you want to edit
|
|
Karsten Hopp |
c85d93 |
+ "resume.txt" first press "q" to stop the listing. You will get a prompt:
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ Type number and <Enter> (empty cancels): ~
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ Type "2" and press <Enter> to edit the second file.
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ More info at |:oldfiles|, |v:oldfiles| and |c_#<|.
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
MOVE INFO FROM ONE VIM TO ANOTHER
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
You can use the ":wviminfo" and ":rviminfo" commands to save and restore the
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/eval.c Thu Nov 6 11:04:50 2008
|
|
Karsten Hopp |
c85d93 |
--- src/eval.c Sun Nov 9 11:59:39 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 348,353 ****
|
|
Karsten Hopp |
c85d93 |
--- 348,354 ----
|
|
Karsten Hopp |
c85d93 |
{VV_NAME("mouse_col", VAR_NUMBER), 0},
|
|
Karsten Hopp |
c85d93 |
{VV_NAME("operator", VAR_STRING), VV_RO},
|
|
Karsten Hopp |
c85d93 |
{VV_NAME("searchforward", VAR_NUMBER), 0},
|
|
Karsten Hopp |
c85d93 |
+ {VV_NAME("oldfiles", VAR_LIST), 0},
|
|
Karsten Hopp |
c85d93 |
};
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/* shorthand */
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 355,360 ****
|
|
Karsten Hopp |
c85d93 |
--- 356,362 ----
|
|
Karsten Hopp |
c85d93 |
#define vv_nr vv_di.di_tv.vval.v_number
|
|
Karsten Hopp |
c85d93 |
#define vv_float vv_di.di_tv.vval.v_float
|
|
Karsten Hopp |
c85d93 |
#define vv_str vv_di.di_tv.vval.v_string
|
|
Karsten Hopp |
c85d93 |
+ #define vv_list vv_di.di_tv.vval.v_list
|
|
Karsten Hopp |
c85d93 |
#define vv_tv vv_di.di_tv
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 426,432 ****
|
|
Karsten Hopp |
c85d93 |
static long list_idx_of_item __ARGS((list_T *l, listitem_T *item));
|
|
Karsten Hopp |
c85d93 |
static void list_append __ARGS((list_T *l, listitem_T *item));
|
|
Karsten Hopp |
c85d93 |
static int list_append_tv __ARGS((list_T *l, typval_T *tv));
|
|
Karsten Hopp |
c85d93 |
- static int list_append_string __ARGS((list_T *l, char_u *str, int len));
|
|
Karsten Hopp |
c85d93 |
static int list_append_number __ARGS((list_T *l, varnumber_T n));
|
|
Karsten Hopp |
c85d93 |
static int list_insert_tv __ARGS((list_T *l, typval_T *tv, listitem_T *item));
|
|
Karsten Hopp |
c85d93 |
static int list_extend __ARGS((list_T *l1, list_T *l2, listitem_T *bef));
|
|
Karsten Hopp |
c85d93 |
--- 428,433 ----
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 845,852 ****
|
|
Karsten Hopp |
c85d93 |
p = &vimvars[i];
|
|
Karsten Hopp |
c85d93 |
if (p->vv_di.di_tv.v_type == VAR_STRING)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! vim_free(p->vv_di.di_tv.vval.v_string);
|
|
Karsten Hopp |
c85d93 |
! p->vv_di.di_tv.vval.v_string = NULL;
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
hash_clear(&vimvarht);
|
|
Karsten Hopp |
c85d93 |
--- 846,858 ----
|
|
Karsten Hopp |
c85d93 |
p = &vimvars[i];
|
|
Karsten Hopp |
c85d93 |
if (p->vv_di.di_tv.v_type == VAR_STRING)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! vim_free(p->vv_string);
|
|
Karsten Hopp |
c85d93 |
! p->vv_string = NULL;
|
|
Karsten Hopp |
c85d93 |
! }
|
|
Karsten Hopp |
c85d93 |
! else if (p->vv_di.di_tv.v_type == VAR_LIST)
|
|
Karsten Hopp |
c85d93 |
! {
|
|
Karsten Hopp |
c85d93 |
! list_unref(p->vv_list);
|
|
Karsten Hopp |
c85d93 |
! p->vv_list = NULL;
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
hash_clear(&vimvarht);
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 6057,6062 ****
|
|
Karsten Hopp |
c85d93 |
--- 6063,6087 ----
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
+ * Get list item "l[idx - 1]" as a string. Returns NULL for failure.
|
|
Karsten Hopp |
c85d93 |
+ */
|
|
Karsten Hopp |
c85d93 |
+ char_u *
|
|
Karsten Hopp |
c85d93 |
+ list_find_str(l, idx)
|
|
Karsten Hopp |
c85d93 |
+ list_T *l;
|
|
Karsten Hopp |
c85d93 |
+ long idx;
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ listitem_T *li;
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ li = list_find(l, idx - 1);
|
|
Karsten Hopp |
c85d93 |
+ if (li == NULL)
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ EMSGN(_(e_listidx), idx);
|
|
Karsten Hopp |
c85d93 |
+ return NULL;
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+ return get_tv_string(&li->li_tv);
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ /*
|
|
Karsten Hopp |
c85d93 |
* Locate "item" list "l" and return its index.
|
|
Karsten Hopp |
c85d93 |
* Returns -1 when "item" is not in the list.
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 6147,6153 ****
|
|
Karsten Hopp |
c85d93 |
* When "len" >= 0 use "str[len]".
|
|
Karsten Hopp |
c85d93 |
* Returns FAIL when out of memory.
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
! static int
|
|
Karsten Hopp |
c85d93 |
list_append_string(l, str, len)
|
|
Karsten Hopp |
c85d93 |
list_T *l;
|
|
Karsten Hopp |
c85d93 |
char_u *str;
|
|
Karsten Hopp |
c85d93 |
--- 6172,6178 ----
|
|
Karsten Hopp |
c85d93 |
* When "len" >= 0 use "str[len]".
|
|
Karsten Hopp |
c85d93 |
* Returns FAIL when out of memory.
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
! int
|
|
Karsten Hopp |
c85d93 |
list_append_string(l, str, len)
|
|
Karsten Hopp |
c85d93 |
list_T *l;
|
|
Karsten Hopp |
c85d93 |
char_u *str;
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 6507,6512 ****
|
|
Karsten Hopp |
c85d93 |
--- 6532,6540 ----
|
|
Karsten Hopp |
c85d93 |
set_ref_in_ht(&fc->l_avars.dv_hashtab, copyID);
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
+ /* v: vars */
|
|
Karsten Hopp |
c85d93 |
+ set_ref_in_ht(&vimvarht, copyID);
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
* 2. Go through the list of dicts and free items without the copyID.
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 6597,6603 ****
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
case VAR_DICT:
|
|
Karsten Hopp |
c85d93 |
dd = tv->vval.v_dict;
|
|
Karsten Hopp |
c85d93 |
! if (dd->dv_copyID != copyID)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
/* Didn't see this dict yet. */
|
|
Karsten Hopp |
c85d93 |
dd->dv_copyID = copyID;
|
|
Karsten Hopp |
c85d93 |
--- 6625,6631 ----
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
case VAR_DICT:
|
|
Karsten Hopp |
c85d93 |
dd = tv->vval.v_dict;
|
|
Karsten Hopp |
c85d93 |
! if (dd != NULL && dd->dv_copyID != copyID)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
/* Didn't see this dict yet. */
|
|
Karsten Hopp |
c85d93 |
dd->dv_copyID = copyID;
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 6607,6613 ****
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
case VAR_LIST:
|
|
Karsten Hopp |
c85d93 |
ll = tv->vval.v_list;
|
|
Karsten Hopp |
c85d93 |
! if (ll->lv_copyID != copyID)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
/* Didn't see this list yet. */
|
|
Karsten Hopp |
c85d93 |
ll->lv_copyID = copyID;
|
|
Karsten Hopp |
c85d93 |
--- 6635,6641 ----
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
case VAR_LIST:
|
|
Karsten Hopp |
c85d93 |
ll = tv->vval.v_list;
|
|
Karsten Hopp |
c85d93 |
! if (ll != NULL && ll->lv_copyID != copyID)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
/* Didn't see this list yet. */
|
|
Karsten Hopp |
c85d93 |
ll->lv_copyID = copyID;
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 18106,18111 ****
|
|
Karsten Hopp |
c85d93 |
--- 18134,18150 ----
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
+ * Get List v: variable value. Caller must take care of reference count when
|
|
Karsten Hopp |
c85d93 |
+ * needed.
|
|
Karsten Hopp |
c85d93 |
+ */
|
|
Karsten Hopp |
c85d93 |
+ list_T *
|
|
Karsten Hopp |
c85d93 |
+ get_vim_var_list(idx)
|
|
Karsten Hopp |
c85d93 |
+ int idx;
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ return vimvars[idx].vv_list;
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ /*
|
|
Karsten Hopp |
c85d93 |
* Set v:count, v:count1 and v:prevcount.
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
void
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 18141,18146 ****
|
|
Karsten Hopp |
c85d93 |
--- 18180,18199 ----
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
+ * Set List v: variable to "val".
|
|
Karsten Hopp |
c85d93 |
+ */
|
|
Karsten Hopp |
c85d93 |
+ void
|
|
Karsten Hopp |
c85d93 |
+ set_vim_var_list(idx, val)
|
|
Karsten Hopp |
c85d93 |
+ int idx;
|
|
Karsten Hopp |
c85d93 |
+ list_T *val;
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ list_unref(vimvars[idx].vv_list);
|
|
Karsten Hopp |
c85d93 |
+ vimvars[idx].vv_list = val;
|
|
Karsten Hopp |
c85d93 |
+ if (val != NULL)
|
|
Karsten Hopp |
c85d93 |
+ ++val->lv_refcount;
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ /*
|
|
Karsten Hopp |
c85d93 |
* Set v:register if needed.
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
void
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 21900,21905 ****
|
|
Karsten Hopp |
c85d93 |
--- 21953,22014 ----
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
+ /*
|
|
Karsten Hopp |
c85d93 |
+ * List v:oldfiles in a nice way.
|
|
Karsten Hopp |
c85d93 |
+ */
|
|
Karsten Hopp |
c85d93 |
+ /*ARGSUSED*/
|
|
Karsten Hopp |
c85d93 |
+ void
|
|
Karsten Hopp |
c85d93 |
+ ex_oldfiles(eap)
|
|
Karsten Hopp |
c85d93 |
+ exarg_T *eap;
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ list_T *l = vimvars[VV_OLDFILES].vv_list;
|
|
Karsten Hopp |
c85d93 |
+ listitem_T *li;
|
|
Karsten Hopp |
c85d93 |
+ int nr = 0;
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ if (l == NULL)
|
|
Karsten Hopp |
c85d93 |
+ msg((char_u *)_("No old files"));
|
|
Karsten Hopp |
c85d93 |
+ else
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ msg_start();
|
|
Karsten Hopp |
c85d93 |
+ msg_scroll = TRUE;
|
|
Karsten Hopp |
c85d93 |
+ for (li = l->lv_first; li != NULL && !got_int; li = li->li_next)
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ msg_outnum((long)++nr);
|
|
Karsten Hopp |
c85d93 |
+ MSG_PUTS(": ");
|
|
Karsten Hopp |
c85d93 |
+ msg_outtrans(get_tv_string(&li->li_tv));
|
|
Karsten Hopp |
c85d93 |
+ msg_putchar('\n');
|
|
Karsten Hopp |
c85d93 |
+ out_flush(); /* output one line at a time */
|
|
Karsten Hopp |
c85d93 |
+ ui_breakcheck();
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+ /* Assume "got_int" was set to truncate the listing. */
|
|
Karsten Hopp |
c85d93 |
+ got_int = FALSE;
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ #ifdef FEAT_BROWSE_CMD
|
|
Karsten Hopp |
c85d93 |
+ if (cmdmod.browse)
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ quit_more = FALSE;
|
|
Karsten Hopp |
c85d93 |
+ nr = prompt_for_number(FALSE);
|
|
Karsten Hopp |
c85d93 |
+ msg_starthere();
|
|
Karsten Hopp |
c85d93 |
+ if (nr > 0)
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ char_u *p = list_find_str(get_vim_var_list(VV_OLDFILES),
|
|
Karsten Hopp |
c85d93 |
+ (long)nr);
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ if (p != NULL)
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ p = expand_env_save(p);
|
|
Karsten Hopp |
c85d93 |
+ eap->arg = p;
|
|
Karsten Hopp |
c85d93 |
+ eap->cmdidx = CMD_edit;
|
|
Karsten Hopp |
c85d93 |
+ cmdmod.browse = FALSE;
|
|
Karsten Hopp |
c85d93 |
+ do_exedit(eap, NULL);
|
|
Karsten Hopp |
c85d93 |
+ vim_free(p);
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+ #endif
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
#endif /* FEAT_EVAL */
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/ex_cmds.c Sun Sep 14 21:40:26 2008
|
|
Karsten Hopp |
c85d93 |
--- src/ex_cmds.c Sun Sep 14 13:45:03 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 24,30 ****
|
|
Karsten Hopp |
c85d93 |
static void do_filter __ARGS((linenr_T line1, linenr_T line2, exarg_T *eap, char_u *cmd, int do_in, int do_out));
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_VIMINFO
|
|
Karsten Hopp |
c85d93 |
static char_u *viminfo_filename __ARGS((char_u *));
|
|
Karsten Hopp |
c85d93 |
! static void do_viminfo __ARGS((FILE *fp_in, FILE *fp_out, int want_info, int want_marks, int force_read));
|
|
Karsten Hopp |
c85d93 |
static int viminfo_encoding __ARGS((vir_T *virp));
|
|
Karsten Hopp |
c85d93 |
static int read_viminfo_up_to_marks __ARGS((vir_T *virp, int forceit, int writing));
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
--- 24,30 ----
|
|
Karsten Hopp |
c85d93 |
static void do_filter __ARGS((linenr_T line1, linenr_T line2, exarg_T *eap, char_u *cmd, int do_in, int do_out));
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_VIMINFO
|
|
Karsten Hopp |
c85d93 |
static char_u *viminfo_filename __ARGS((char_u *));
|
|
Karsten Hopp |
c85d93 |
! static void do_viminfo __ARGS((FILE *fp_in, FILE *fp_out, int flags));
|
|
Karsten Hopp |
c85d93 |
static int viminfo_encoding __ARGS((vir_T *virp));
|
|
Karsten Hopp |
c85d93 |
static int read_viminfo_up_to_marks __ARGS((vir_T *virp, int forceit, int writing));
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1676,1689 ****
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
* read_viminfo() -- Read the viminfo file. Registers etc. which are already
|
|
Karsten Hopp |
c85d93 |
! * set are not over-written unless force is TRUE. -- webb
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
int
|
|
Karsten Hopp |
c85d93 |
! read_viminfo(file, want_info, want_marks, forceit)
|
|
Karsten Hopp |
c85d93 |
! char_u *file;
|
|
Karsten Hopp |
c85d93 |
! int want_info;
|
|
Karsten Hopp |
c85d93 |
! int want_marks;
|
|
Karsten Hopp |
c85d93 |
! int forceit;
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
FILE *fp;
|
|
Karsten Hopp |
c85d93 |
char_u *fname;
|
|
Karsten Hopp |
c85d93 |
--- 1676,1687 ----
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
* read_viminfo() -- Read the viminfo file. Registers etc. which are already
|
|
Karsten Hopp |
c85d93 |
! * set are not over-written unless "flags" includes VIF_FORCEIT. -- webb
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
int
|
|
Karsten Hopp |
c85d93 |
! read_viminfo(file, flags)
|
|
Karsten Hopp |
c85d93 |
! char_u *file; /* file name or NULL to use default name */
|
|
Karsten Hopp |
c85d93 |
! int flags; /* VIF_WANT_INFO et al. */
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
FILE *fp;
|
|
Karsten Hopp |
c85d93 |
char_u *fname;
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1691,1697 ****
|
|
Karsten Hopp |
c85d93 |
if (no_viminfo())
|
|
Karsten Hopp |
c85d93 |
return FAIL;
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
! fname = viminfo_filename(file); /* may set to default if NULL */
|
|
Karsten Hopp |
c85d93 |
if (fname == NULL)
|
|
Karsten Hopp |
c85d93 |
return FAIL;
|
|
Karsten Hopp |
c85d93 |
fp = mch_fopen((char *)fname, READBIN);
|
|
Karsten Hopp |
c85d93 |
--- 1689,1695 ----
|
|
Karsten Hopp |
c85d93 |
if (no_viminfo())
|
|
Karsten Hopp |
c85d93 |
return FAIL;
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
! fname = viminfo_filename(file); /* get file name in allocated buffer */
|
|
Karsten Hopp |
c85d93 |
if (fname == NULL)
|
|
Karsten Hopp |
c85d93 |
return FAIL;
|
|
Karsten Hopp |
c85d93 |
fp = mch_fopen((char *)fname, READBIN);
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1701,1708 ****
|
|
Karsten Hopp |
c85d93 |
verbose_enter();
|
|
Karsten Hopp |
c85d93 |
smsg((char_u *)_("Reading viminfo file \"%s\"%s%s%s"),
|
|
Karsten Hopp |
c85d93 |
fname,
|
|
Karsten Hopp |
c85d93 |
! want_info ? _(" info") : "",
|
|
Karsten Hopp |
c85d93 |
! want_marks ? _(" marks") : "",
|
|
Karsten Hopp |
c85d93 |
fp == NULL ? _(" FAILED") : "");
|
|
Karsten Hopp |
c85d93 |
verbose_leave();
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
--- 1699,1707 ----
|
|
Karsten Hopp |
c85d93 |
verbose_enter();
|
|
Karsten Hopp |
c85d93 |
smsg((char_u *)_("Reading viminfo file \"%s\"%s%s%s"),
|
|
Karsten Hopp |
c85d93 |
fname,
|
|
Karsten Hopp |
c85d93 |
! (flags & VIF_WANT_INFO) ? _(" info") : "",
|
|
Karsten Hopp |
c85d93 |
! (flags & VIF_WANT_MARKS) ? _(" marks") : "",
|
|
Karsten Hopp |
c85d93 |
! (flags & VIF_GET_OLDFILES) ? _(" oldfiles") : "",
|
|
Karsten Hopp |
c85d93 |
fp == NULL ? _(" FAILED") : "");
|
|
Karsten Hopp |
c85d93 |
verbose_leave();
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1712,1721 ****
|
|
Karsten Hopp |
c85d93 |
return FAIL;
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
viminfo_errcnt = 0;
|
|
Karsten Hopp |
c85d93 |
! do_viminfo(fp, NULL, want_info, want_marks, forceit);
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
fclose(fp);
|
|
Karsten Hopp |
c85d93 |
-
|
|
Karsten Hopp |
c85d93 |
return OK;
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
--- 1711,1719 ----
|
|
Karsten Hopp |
c85d93 |
return FAIL;
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
viminfo_errcnt = 0;
|
|
Karsten Hopp |
c85d93 |
! do_viminfo(fp, NULL, flags);
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
fclose(fp);
|
|
Karsten Hopp |
c85d93 |
return OK;
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1968,1974 ****
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
viminfo_errcnt = 0;
|
|
Karsten Hopp |
c85d93 |
! do_viminfo(fp_in, fp_out, !forceit, !forceit, FALSE);
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
fclose(fp_out); /* errors are ignored !? */
|
|
Karsten Hopp |
c85d93 |
if (fp_in != NULL)
|
|
Karsten Hopp |
c85d93 |
--- 1966,1972 ----
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
viminfo_errcnt = 0;
|
|
Karsten Hopp |
c85d93 |
! do_viminfo(fp_in, fp_out, forceit ? 0 : (VIF_WANT_INFO | VIF_WANT_MARKS));
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
fclose(fp_out); /* errors are ignored !? */
|
|
Karsten Hopp |
c85d93 |
if (fp_in != NULL)
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 2041,2052 ****
|
|
Karsten Hopp |
c85d93 |
* do_viminfo() -- Should only be called from read_viminfo() & write_viminfo().
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
static void
|
|
Karsten Hopp |
c85d93 |
! do_viminfo(fp_in, fp_out, want_info, want_marks, force_read)
|
|
Karsten Hopp |
c85d93 |
FILE *fp_in;
|
|
Karsten Hopp |
c85d93 |
FILE *fp_out;
|
|
Karsten Hopp |
c85d93 |
! int want_info;
|
|
Karsten Hopp |
c85d93 |
! int want_marks;
|
|
Karsten Hopp |
c85d93 |
! int force_read;
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
int count = 0;
|
|
Karsten Hopp |
c85d93 |
int eof = FALSE;
|
|
Karsten Hopp |
c85d93 |
--- 2039,2048 ----
|
|
Karsten Hopp |
c85d93 |
* do_viminfo() -- Should only be called from read_viminfo() & write_viminfo().
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
static void
|
|
Karsten Hopp |
c85d93 |
! do_viminfo(fp_in, fp_out, flags)
|
|
Karsten Hopp |
c85d93 |
FILE *fp_in;
|
|
Karsten Hopp |
c85d93 |
FILE *fp_out;
|
|
Karsten Hopp |
c85d93 |
! int flags;
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
int count = 0;
|
|
Karsten Hopp |
c85d93 |
int eof = FALSE;
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 2061,2068 ****
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
if (fp_in != NULL)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! if (want_info)
|
|
Karsten Hopp |
c85d93 |
! eof = read_viminfo_up_to_marks(&vir, force_read, fp_out != NULL);
|
|
Karsten Hopp |
c85d93 |
else
|
|
Karsten Hopp |
c85d93 |
/* Skip info, find start of marks */
|
|
Karsten Hopp |
c85d93 |
while (!(eof = viminfo_readline(&vir))
|
|
Karsten Hopp |
c85d93 |
--- 2057,2065 ----
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
if (fp_in != NULL)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! if (flags & VIF_WANT_INFO)
|
|
Karsten Hopp |
c85d93 |
! eof = read_viminfo_up_to_marks(&vir,
|
|
Karsten Hopp |
c85d93 |
! flags & VIF_FORCEIT, fp_out != NULL);
|
|
Karsten Hopp |
c85d93 |
else
|
|
Karsten Hopp |
c85d93 |
/* Skip info, find start of marks */
|
|
Karsten Hopp |
c85d93 |
while (!(eof = viminfo_readline(&vir))
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 2092,2099 ****
|
|
Karsten Hopp |
c85d93 |
write_viminfo_bufferlist(fp_out);
|
|
Karsten Hopp |
c85d93 |
count = write_viminfo_marks(fp_out);
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
! if (fp_in != NULL && want_marks)
|
|
Karsten Hopp |
c85d93 |
! copy_viminfo_marks(&vir, fp_out, count, eof);
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
vim_free(vir.vir_line);
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_MBYTE
|
|
Karsten Hopp |
c85d93 |
--- 2089,2097 ----
|
|
Karsten Hopp |
c85d93 |
write_viminfo_bufferlist(fp_out);
|
|
Karsten Hopp |
c85d93 |
count = write_viminfo_marks(fp_out);
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
! if (fp_in != NULL
|
|
Karsten Hopp |
c85d93 |
! && (flags & (VIF_WANT_MARKS | VIF_GET_OLDFILES | VIF_FORCEIT)))
|
|
Karsten Hopp |
c85d93 |
! copy_viminfo_marks(&vir, fp_out, count, eof, flags);
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
vim_free(vir.vir_line);
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_MBYTE
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/ex_cmds.h Thu Nov 6 20:47:00 2008
|
|
Karsten Hopp |
c85d93 |
--- src/ex_cmds.h Thu Sep 18 22:18:14 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 653,658 ****
|
|
Karsten Hopp |
c85d93 |
--- 653,660 ----
|
|
Karsten Hopp |
c85d93 |
EXTRA|TRLBAR|NOTRLCOM|USECTRLV|CMDWIN),
|
|
Karsten Hopp |
c85d93 |
EX(CMD_open, "open", ex_open,
|
|
Karsten Hopp |
c85d93 |
RANGE|EXTRA),
|
|
Karsten Hopp |
c85d93 |
+ EX(CMD_oldfiles, "oldfiles", ex_oldfiles,
|
|
Karsten Hopp |
c85d93 |
+ BANG|TRLBAR|SBOXOK|CMDWIN),
|
|
Karsten Hopp |
c85d93 |
EX(CMD_omap, "omap", ex_map,
|
|
Karsten Hopp |
c85d93 |
EXTRA|TRLBAR|NOTRLCOM|USECTRLV|CMDWIN),
|
|
Karsten Hopp |
c85d93 |
EX(CMD_omapclear, "omapclear", ex_mapclear,
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/ex_docmd.c Thu Nov 6 17:16:06 2008
|
|
Karsten Hopp |
c85d93 |
--- src/ex_docmd.c Mon Nov 3 21:21:17 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 364,369 ****
|
|
Karsten Hopp |
c85d93 |
--- 364,370 ----
|
|
Karsten Hopp |
c85d93 |
# define ex_function ex_ni
|
|
Karsten Hopp |
c85d93 |
# define ex_delfunction ex_ni
|
|
Karsten Hopp |
c85d93 |
# define ex_return ex_ni
|
|
Karsten Hopp |
c85d93 |
+ # define ex_oldfiles ex_ni
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
static char_u *arg_all __ARGS((void));
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_SESSION
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1770,1776 ****
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
if (checkforcmd(&ea.cmd, "browse", 3))
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! #ifdef FEAT_BROWSE
|
|
Karsten Hopp |
c85d93 |
cmdmod.browse = TRUE;
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
continue;
|
|
Karsten Hopp |
c85d93 |
--- 1771,1777 ----
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
if (checkforcmd(&ea.cmd, "browse", 3))
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! #ifdef FEAT_BROWSE_CMD
|
|
Karsten Hopp |
c85d93 |
cmdmod.browse = TRUE;
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
continue;
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 9508,9531 ****
|
|
Karsten Hopp |
c85d93 |
break;
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
s = src + 1;
|
|
Karsten Hopp |
c85d93 |
i = (int)getdigits(&s);
|
|
Karsten Hopp |
c85d93 |
*usedlen = (int)(s - src); /* length of what we expand */
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
! buf = buflist_findnr(i);
|
|
Karsten Hopp |
c85d93 |
! if (buf == NULL)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! *errormsg = (char_u *)_("E194: No alternate file name to substitute for '#'");
|
|
Karsten Hopp |
c85d93 |
return NULL;
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
! if (lnump != NULL)
|
|
Karsten Hopp |
c85d93 |
! *lnump = ECMD_LAST;
|
|
Karsten Hopp |
c85d93 |
! if (buf->b_fname == NULL)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! result = (char_u *)"";
|
|
Karsten Hopp |
c85d93 |
! valid = 0; /* Must have ":p:h" to be valid */
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
- else
|
|
Karsten Hopp |
c85d93 |
- result = buf->b_fname;
|
|
Karsten Hopp |
c85d93 |
break;
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_SEARCHPATH
|
|
Karsten Hopp |
c85d93 |
--- 9509,9558 ----
|
|
Karsten Hopp |
c85d93 |
break;
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
s = src + 1;
|
|
Karsten Hopp |
c85d93 |
+ if (*s == '<') /* "#<99" uses v:oldfiles */
|
|
Karsten Hopp |
c85d93 |
+ ++s;
|
|
Karsten Hopp |
c85d93 |
i = (int)getdigits(&s);
|
|
Karsten Hopp |
c85d93 |
*usedlen = (int)(s - src); /* length of what we expand */
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
! if (src[1] == '<')
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! if (*usedlen < 2)
|
|
Karsten Hopp |
c85d93 |
! {
|
|
Karsten Hopp |
c85d93 |
! /* Should we give an error message for #
|
|
Karsten Hopp |
c85d93 |
! *usedlen = 1;
|
|
Karsten Hopp |
c85d93 |
! return NULL;
|
|
Karsten Hopp |
c85d93 |
! }
|
|
Karsten Hopp |
c85d93 |
! #ifdef FEAT_EVAL
|
|
Karsten Hopp |
c85d93 |
! result = list_find_str(get_vim_var_list(VV_OLDFILES),
|
|
Karsten Hopp |
c85d93 |
! (long)i);
|
|
Karsten Hopp |
c85d93 |
! if (result == NULL)
|
|
Karsten Hopp |
c85d93 |
! {
|
|
Karsten Hopp |
c85d93 |
! *errormsg = (char_u *)"";
|
|
Karsten Hopp |
c85d93 |
! return NULL;
|
|
Karsten Hopp |
c85d93 |
! }
|
|
Karsten Hopp |
c85d93 |
! #else
|
|
Karsten Hopp |
c85d93 |
! *errormsg = (char_u *)_("E809: #< is not available without the +eval feature");
|
|
Karsten Hopp |
c85d93 |
return NULL;
|
|
Karsten Hopp |
c85d93 |
+ #endif
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
! else
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! buf = buflist_findnr(i);
|
|
Karsten Hopp |
c85d93 |
! if (buf == NULL)
|
|
Karsten Hopp |
c85d93 |
! {
|
|
Karsten Hopp |
c85d93 |
! *errormsg = (char_u *)_("E194: No alternate file name to substitute for '#'");
|
|
Karsten Hopp |
c85d93 |
! return NULL;
|
|
Karsten Hopp |
c85d93 |
! }
|
|
Karsten Hopp |
c85d93 |
! if (lnump != NULL)
|
|
Karsten Hopp |
c85d93 |
! *lnump = ECMD_LAST;
|
|
Karsten Hopp |
c85d93 |
! if (buf->b_fname == NULL)
|
|
Karsten Hopp |
c85d93 |
! {
|
|
Karsten Hopp |
c85d93 |
! result = (char_u *)"";
|
|
Karsten Hopp |
c85d93 |
! valid = 0; /* Must have ":p:h" to be valid */
|
|
Karsten Hopp |
c85d93 |
! }
|
|
Karsten Hopp |
c85d93 |
! else
|
|
Karsten Hopp |
c85d93 |
! result = buf->b_fname;
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
break;
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_SEARCHPATH
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 10700,10706 ****
|
|
Karsten Hopp |
c85d93 |
p_viminfo = (char_u *)"'100";
|
|
Karsten Hopp |
c85d93 |
if (eap->cmdidx == CMD_rviminfo)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! if (read_viminfo(eap->arg, TRUE, TRUE, eap->forceit) == FAIL)
|
|
Karsten Hopp |
c85d93 |
EMSG(_("E195: Cannot open viminfo file for reading"));
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
else
|
|
Karsten Hopp |
c85d93 |
--- 10727,10734 ----
|
|
Karsten Hopp |
c85d93 |
p_viminfo = (char_u *)"'100";
|
|
Karsten Hopp |
c85d93 |
if (eap->cmdidx == CMD_rviminfo)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! if (read_viminfo(eap->arg, VIF_WANT_INFO | VIF_WANT_MARKS
|
|
Karsten Hopp |
c85d93 |
! | (eap->forceit ? VIF_FORCEIT : 0)) == FAIL)
|
|
Karsten Hopp |
c85d93 |
EMSG(_("E195: Cannot open viminfo file for reading"));
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
else
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/feature.h Wed Aug 6 18:45:07 2008
|
|
Karsten Hopp |
c85d93 |
--- src/feature.h Fri Sep 19 19:14:22 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 767,775 ****
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
* +browse ":browse" command.
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
! #if defined(FEAT_NORMAL) && (defined(FEAT_GUI_MSWIN) || defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA) || defined(FEAT_GUI_GTK) || defined(FEAT_GUI_PHOTON) || defined(FEAT_GUI_MAC))
|
|
Karsten Hopp |
c85d93 |
! # define FEAT_BROWSE
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
--- 767,779 ----
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
* +browse ":browse" command.
|
|
Karsten Hopp |
c85d93 |
+ * or just the ":browse" command modifier
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
! #if defined(FEAT_NORMAL)
|
|
Karsten Hopp |
c85d93 |
! # define FEAT_BROWSE_CMD
|
|
Karsten Hopp |
c85d93 |
! # if defined(FEAT_GUI_MSWIN) || defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA) || defined(FEAT_GUI_GTK) || defined(FEAT_GUI_PHOTON) || defined(FEAT_GUI_MAC)
|
|
Karsten Hopp |
c85d93 |
! # define FEAT_BROWSE
|
|
Karsten Hopp |
c85d93 |
! # endif
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/fileio.c Thu Sep 18 21:29:07 2008
|
|
Karsten Hopp |
c85d93 |
--- src/fileio.c Mon Nov 3 21:21:47 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 2711,2717 ****
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
if (!curbuf->b_marks_read && get_viminfo_parameter('\'') > 0
|
|
Karsten Hopp |
c85d93 |
&& curbuf->b_ffname != NULL)
|
|
Karsten Hopp |
c85d93 |
! read_viminfo(NULL, FALSE, TRUE, FALSE);
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/* Always set b_marks_read; needed when 'viminfo' is changed to include
|
|
Karsten Hopp |
c85d93 |
* the ' parameter after opening a buffer. */
|
|
Karsten Hopp |
c85d93 |
--- 2711,2717 ----
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
if (!curbuf->b_marks_read && get_viminfo_parameter('\'') > 0
|
|
Karsten Hopp |
c85d93 |
&& curbuf->b_ffname != NULL)
|
|
Karsten Hopp |
c85d93 |
! read_viminfo(NULL, VIF_WANT_MARKS);
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/* Always set b_marks_read; needed when 'viminfo' is changed to include
|
|
Karsten Hopp |
c85d93 |
* the ' parameter after opening a buffer. */
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 9108,9114 ****
|
|
Karsten Hopp |
c85d93 |
set_context_in_autocmd(xp, arg, doautocmd)
|
|
Karsten Hopp |
c85d93 |
expand_T *xp;
|
|
Karsten Hopp |
c85d93 |
char_u *arg;
|
|
Karsten Hopp |
c85d93 |
! int doautocmd; /* TRUE for :doautocmd, FALSE for :autocmd */
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
char_u *p;
|
|
Karsten Hopp |
c85d93 |
int group;
|
|
Karsten Hopp |
c85d93 |
--- 9109,9115 ----
|
|
Karsten Hopp |
c85d93 |
set_context_in_autocmd(xp, arg, doautocmd)
|
|
Karsten Hopp |
c85d93 |
expand_T *xp;
|
|
Karsten Hopp |
c85d93 |
char_u *arg;
|
|
Karsten Hopp |
c85d93 |
! int doautocmd; /* TRUE for :doauto*, FALSE for :autocmd */
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
char_u *p;
|
|
Karsten Hopp |
c85d93 |
int group;
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/main.c Thu Sep 18 20:55:19 2008
|
|
Karsten Hopp |
c85d93 |
--- src/main.c Sun Sep 14 13:26:10 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 645,655 ****
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_VIMINFO
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
! * Read in registers, history etc, but not marks, from the viminfo file
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
if (*p_viminfo != NUL)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! read_viminfo(NULL, TRUE, FALSE, FALSE);
|
|
Karsten Hopp |
c85d93 |
TIME_MSG("reading viminfo");
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
--- 645,656 ----
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_VIMINFO
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
! * Read in registers, history etc, but not marks, from the viminfo file.
|
|
Karsten Hopp |
c85d93 |
! * This is where v:oldfiles gets filled.
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
if (*p_viminfo != NUL)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! read_viminfo(NULL, VIF_WANT_INFO | VIF_GET_OLDFILES);
|
|
Karsten Hopp |
c85d93 |
TIME_MSG("reading viminfo");
|
|
Karsten Hopp |
c85d93 |
}
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/mark.c Sat Aug 9 19:37:29 2008
|
|
Karsten Hopp |
c85d93 |
--- src/mark.c Sun Sep 14 13:46:19 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1627,1641 ****
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
* Handle marks in the viminfo file:
|
|
Karsten Hopp |
c85d93 |
! * fp_out == NULL read marks for current buffer only
|
|
Karsten Hopp |
c85d93 |
! * fp_out != NULL copy marks for buffers not in buffer list
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
void
|
|
Karsten Hopp |
c85d93 |
! copy_viminfo_marks(virp, fp_out, count, eof)
|
|
Karsten Hopp |
c85d93 |
vir_T *virp;
|
|
Karsten Hopp |
c85d93 |
FILE *fp_out;
|
|
Karsten Hopp |
c85d93 |
int count;
|
|
Karsten Hopp |
c85d93 |
int eof;
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
char_u *line = virp->vir_line;
|
|
Karsten Hopp |
c85d93 |
buf_T *buf;
|
|
Karsten Hopp |
c85d93 |
--- 1627,1643 ----
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
* Handle marks in the viminfo file:
|
|
Karsten Hopp |
c85d93 |
! * fp_out != NULL: copy marks for buffers not in buffer list
|
|
Karsten Hopp |
c85d93 |
! * fp_out == NULL && (flags & VIF_WANT_MARKS): read marks for curbuf only
|
|
Karsten Hopp |
c85d93 |
! * fp_out == NULL && (flags & VIF_GET_OLDFILES | VIF_FORCEIT): fill v:oldfiles
|
|
Karsten Hopp |
c85d93 |
*/
|
|
Karsten Hopp |
c85d93 |
void
|
|
Karsten Hopp |
c85d93 |
! copy_viminfo_marks(virp, fp_out, count, eof, flags)
|
|
Karsten Hopp |
c85d93 |
vir_T *virp;
|
|
Karsten Hopp |
c85d93 |
FILE *fp_out;
|
|
Karsten Hopp |
c85d93 |
int count;
|
|
Karsten Hopp |
c85d93 |
int eof;
|
|
Karsten Hopp |
c85d93 |
+ int flags;
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
char_u *line = virp->vir_line;
|
|
Karsten Hopp |
c85d93 |
buf_T *buf;
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1647,1656 ****
|
|
Karsten Hopp |
c85d93 |
--- 1649,1671 ----
|
|
Karsten Hopp |
c85d93 |
char_u *p;
|
|
Karsten Hopp |
c85d93 |
char_u *name_buf;
|
|
Karsten Hopp |
c85d93 |
pos_T pos;
|
|
Karsten Hopp |
c85d93 |
+ #ifdef FEAT_EVAL
|
|
Karsten Hopp |
c85d93 |
+ list_T *list = NULL;
|
|
Karsten Hopp |
c85d93 |
+ #endif
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
if ((name_buf = alloc(LSIZE)) == NULL)
|
|
Karsten Hopp |
c85d93 |
return;
|
|
Karsten Hopp |
c85d93 |
*name_buf = NUL;
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
+ #ifdef FEAT_EVAL
|
|
Karsten Hopp |
c85d93 |
+ if (fp_out == NULL && (flags & (VIF_GET_OLDFILES | VIF_FORCEIT)))
|
|
Karsten Hopp |
c85d93 |
+ {
|
|
Karsten Hopp |
c85d93 |
+ list = list_alloc();
|
|
Karsten Hopp |
c85d93 |
+ if (list != NULL)
|
|
Karsten Hopp |
c85d93 |
+ set_vim_var_list(VV_OLDFILES, list);
|
|
Karsten Hopp |
c85d93 |
+ }
|
|
Karsten Hopp |
c85d93 |
+ #endif
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
num_marked_files = get_viminfo_parameter('\'');
|
|
Karsten Hopp |
c85d93 |
while (!eof && (count < num_marked_files || fp_out == NULL))
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1681,1686 ****
|
|
Karsten Hopp |
c85d93 |
--- 1696,1706 ----
|
|
Karsten Hopp |
c85d93 |
p++;
|
|
Karsten Hopp |
c85d93 |
*p = NUL;
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
+ #ifdef FEAT_EVAL
|
|
Karsten Hopp |
c85d93 |
+ if (list != NULL)
|
|
Karsten Hopp |
c85d93 |
+ list_append_string(list, str, -1);
|
|
Karsten Hopp |
c85d93 |
+ #endif
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
/*
|
|
Karsten Hopp |
c85d93 |
* If fp_out == NULL, load marks for current buffer.
|
|
Karsten Hopp |
c85d93 |
* If fp_out != NULL, copy marks for buffers not in buflist.
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1688,1694 ****
|
|
Karsten Hopp |
c85d93 |
load_marks = copy_marks_out = FALSE;
|
|
Karsten Hopp |
c85d93 |
if (fp_out == NULL)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! if (curbuf->b_ffname != NULL)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
if (*name_buf == NUL) /* only need to do this once */
|
|
Karsten Hopp |
c85d93 |
home_replace(NULL, curbuf->b_ffname, name_buf, LSIZE, TRUE);
|
|
Karsten Hopp |
c85d93 |
--- 1708,1714 ----
|
|
Karsten Hopp |
c85d93 |
load_marks = copy_marks_out = FALSE;
|
|
Karsten Hopp |
c85d93 |
if (fp_out == NULL)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
! if ((flags & VIF_WANT_MARKS) && curbuf->b_ffname != NULL)
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
if (*name_buf == NUL) /* only need to do this once */
|
|
Karsten Hopp |
c85d93 |
home_replace(NULL, curbuf->b_ffname, name_buf, LSIZE, TRUE);
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/misc1.c Wed Jun 25 00:24:52 2008
|
|
Karsten Hopp |
c85d93 |
--- src/misc1.c Sun Nov 9 11:47:00 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 3245,3253 ****
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/* When using ":silent" assume that <CR> was entered. */
|
|
Karsten Hopp |
c85d93 |
if (mouse_used != NULL)
|
|
Karsten Hopp |
c85d93 |
! MSG_PUTS(_("Type number or click with mouse (<Enter> cancels): "));
|
|
Karsten Hopp |
c85d93 |
else
|
|
Karsten Hopp |
c85d93 |
! MSG_PUTS(_("Choice number (<Enter> cancels): "));
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/* Set the state such that text can be selected/copied/pasted and we still
|
|
Karsten Hopp |
c85d93 |
* get mouse events. */
|
|
Karsten Hopp |
c85d93 |
--- 3245,3253 ----
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/* When using ":silent" assume that <CR> was entered. */
|
|
Karsten Hopp |
c85d93 |
if (mouse_used != NULL)
|
|
Karsten Hopp |
c85d93 |
! MSG_PUTS(_("Type number and <Enter> or click with mouse (empty cancels): "));
|
|
Karsten Hopp |
c85d93 |
else
|
|
Karsten Hopp |
c85d93 |
! MSG_PUTS(_("Type number and <Enter> (empty cancels): "));
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/* Set the state such that text can be selected/copied/pasted and we still
|
|
Karsten Hopp |
c85d93 |
* get mouse events. */
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/proto/eval.pro Sun Jan 6 20:06:30 2008
|
|
Karsten Hopp |
c85d93 |
--- src/proto/eval.pro Sun Nov 9 12:05:56 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 17,23 ****
|
|
Karsten Hopp |
c85d93 |
int eval_to_bool __ARGS((char_u *arg, int *error, char_u **nextcmd, int skip));
|
|
Karsten Hopp |
c85d93 |
char_u *eval_to_string_skip __ARGS((char_u *arg, char_u **nextcmd, int skip));
|
|
Karsten Hopp |
c85d93 |
int skip_expr __ARGS((char_u **pp));
|
|
Karsten Hopp |
c85d93 |
! char_u *eval_to_string __ARGS((char_u *arg, char_u **nextcmd, int dolist));
|
|
Karsten Hopp |
c85d93 |
char_u *eval_to_string_safe __ARGS((char_u *arg, char_u **nextcmd, int use_sandbox));
|
|
Karsten Hopp |
c85d93 |
int eval_to_number __ARGS((char_u *expr));
|
|
Karsten Hopp |
c85d93 |
list_T *eval_spell_expr __ARGS((char_u *badword, char_u *expr));
|
|
Karsten Hopp |
c85d93 |
--- 17,23 ----
|
|
Karsten Hopp |
c85d93 |
int eval_to_bool __ARGS((char_u *arg, int *error, char_u **nextcmd, int skip));
|
|
Karsten Hopp |
c85d93 |
char_u *eval_to_string_skip __ARGS((char_u *arg, char_u **nextcmd, int skip));
|
|
Karsten Hopp |
c85d93 |
int skip_expr __ARGS((char_u **pp));
|
|
Karsten Hopp |
c85d93 |
! char_u *eval_to_string __ARGS((char_u *arg, char_u **nextcmd, int convert));
|
|
Karsten Hopp |
c85d93 |
char_u *eval_to_string_safe __ARGS((char_u *arg, char_u **nextcmd, int use_sandbox));
|
|
Karsten Hopp |
c85d93 |
int eval_to_number __ARGS((char_u *expr));
|
|
Karsten Hopp |
c85d93 |
list_T *eval_spell_expr __ARGS((char_u *badword, char_u *expr));
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 46,52 ****
|
|
Karsten Hopp |
c85d93 |
--- 46,54 ----
|
|
Karsten Hopp |
c85d93 |
void list_unref __ARGS((list_T *l));
|
|
Karsten Hopp |
c85d93 |
void list_free __ARGS((list_T *l, int recurse));
|
|
Karsten Hopp |
c85d93 |
dictitem_T *dict_lookup __ARGS((hashitem_T *hi));
|
|
Karsten Hopp |
c85d93 |
+ char_u *list_find_str __ARGS((list_T *l, long idx));
|
|
Karsten Hopp |
c85d93 |
int list_append_dict __ARGS((list_T *list, dict_T *dict));
|
|
Karsten Hopp |
c85d93 |
+ int list_append_string __ARGS((list_T *l, char_u *str, int len));
|
|
Karsten Hopp |
c85d93 |
int garbage_collect __ARGS((void));
|
|
Karsten Hopp |
c85d93 |
dict_T *dict_alloc __ARGS((void));
|
|
Karsten Hopp |
c85d93 |
int dict_add_nr_str __ARGS((dict_T *d, char *key, long nr, char_u *str));
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 58,65 ****
|
|
Karsten Hopp |
c85d93 |
--- 60,69 ----
|
|
Karsten Hopp |
c85d93 |
void set_vim_var_nr __ARGS((int idx, long val));
|
|
Karsten Hopp |
c85d93 |
long get_vim_var_nr __ARGS((int idx));
|
|
Karsten Hopp |
c85d93 |
char_u *get_vim_var_str __ARGS((int idx));
|
|
Karsten Hopp |
c85d93 |
+ list_T *get_vim_var_list __ARGS((int idx));
|
|
Karsten Hopp |
c85d93 |
void set_vcount __ARGS((long count, long count1));
|
|
Karsten Hopp |
c85d93 |
void set_vim_var_string __ARGS((int idx, char_u *val, int len));
|
|
Karsten Hopp |
c85d93 |
+ void set_vim_var_list __ARGS((int idx, list_T *val));
|
|
Karsten Hopp |
c85d93 |
void set_reg_var __ARGS((int c));
|
|
Karsten Hopp |
c85d93 |
char_u *v_exception __ARGS((char_u *oldval));
|
|
Karsten Hopp |
c85d93 |
char_u *v_throwpoint __ARGS((char_u *oldval));
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 94,99 ****
|
|
Karsten Hopp |
c85d93 |
--- 98,104 ----
|
|
Karsten Hopp |
c85d93 |
void write_viminfo_varlist __ARGS((FILE *fp));
|
|
Karsten Hopp |
c85d93 |
int store_session_globals __ARGS((FILE *fd));
|
|
Karsten Hopp |
c85d93 |
void last_set_msg __ARGS((scid_T scriptID));
|
|
Karsten Hopp |
c85d93 |
+ void ex_oldfiles __ARGS((exarg_T *eap));
|
|
Karsten Hopp |
c85d93 |
int modify_fname __ARGS((char_u *src, int *usedlen, char_u **fnamep, char_u **bufp, int *fnamelen));
|
|
Karsten Hopp |
c85d93 |
char_u *do_string_sub __ARGS((char_u *str, char_u *pat, char_u *sub, char_u *flags));
|
|
Karsten Hopp |
c85d93 |
/* vim: set ft=c : */
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/proto/ex_cmds.pro Sat May 5 20:13:58 2007
|
|
Karsten Hopp |
c85d93 |
--- src/proto/ex_cmds.pro Sat Sep 13 17:27:21 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 11,17 ****
|
|
Karsten Hopp |
c85d93 |
char_u *make_filter_cmd __ARGS((char_u *cmd, char_u *itmp, char_u *otmp));
|
|
Karsten Hopp |
c85d93 |
void append_redir __ARGS((char_u *buf, char_u *opt, char_u *fname));
|
|
Karsten Hopp |
c85d93 |
int viminfo_error __ARGS((char *errnum, char *message, char_u *line));
|
|
Karsten Hopp |
c85d93 |
! int read_viminfo __ARGS((char_u *file, int want_info, int want_marks, int forceit));
|
|
Karsten Hopp |
c85d93 |
void write_viminfo __ARGS((char_u *file, int forceit));
|
|
Karsten Hopp |
c85d93 |
int viminfo_readline __ARGS((vir_T *virp));
|
|
Karsten Hopp |
c85d93 |
char_u *viminfo_readstring __ARGS((vir_T *virp, int off, int convert));
|
|
Karsten Hopp |
c85d93 |
--- 11,17 ----
|
|
Karsten Hopp |
c85d93 |
char_u *make_filter_cmd __ARGS((char_u *cmd, char_u *itmp, char_u *otmp));
|
|
Karsten Hopp |
c85d93 |
void append_redir __ARGS((char_u *buf, char_u *opt, char_u *fname));
|
|
Karsten Hopp |
c85d93 |
int viminfo_error __ARGS((char *errnum, char *message, char_u *line));
|
|
Karsten Hopp |
c85d93 |
! int read_viminfo __ARGS((char_u *file, int flags));
|
|
Karsten Hopp |
c85d93 |
void write_viminfo __ARGS((char_u *file, int forceit));
|
|
Karsten Hopp |
c85d93 |
int viminfo_readline __ARGS((vir_T *virp));
|
|
Karsten Hopp |
c85d93 |
char_u *viminfo_readstring __ARGS((vir_T *virp, int off, int convert));
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/proto/mark.pro Sat May 5 19:29:37 2007
|
|
Karsten Hopp |
c85d93 |
--- src/proto/mark.pro Sat Sep 13 18:06:20 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 26,30 ****
|
|
Karsten Hopp |
c85d93 |
void write_viminfo_filemarks __ARGS((FILE *fp));
|
|
Karsten Hopp |
c85d93 |
int removable __ARGS((char_u *name));
|
|
Karsten Hopp |
c85d93 |
int write_viminfo_marks __ARGS((FILE *fp_out));
|
|
Karsten Hopp |
c85d93 |
! void copy_viminfo_marks __ARGS((vir_T *virp, FILE *fp_out, int count, int eof));
|
|
Karsten Hopp |
c85d93 |
/* vim: set ft=c : */
|
|
Karsten Hopp |
c85d93 |
--- 26,30 ----
|
|
Karsten Hopp |
c85d93 |
void write_viminfo_filemarks __ARGS((FILE *fp));
|
|
Karsten Hopp |
c85d93 |
int removable __ARGS((char_u *name));
|
|
Karsten Hopp |
c85d93 |
int write_viminfo_marks __ARGS((FILE *fp_out));
|
|
Karsten Hopp |
c85d93 |
! void copy_viminfo_marks __ARGS((vir_T *virp, FILE *fp_out, int count, int eof, int flags));
|
|
Karsten Hopp |
c85d93 |
/* vim: set ft=c : */
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/option.c Thu Oct 2 22:48:01 2008
|
|
Karsten Hopp |
c85d93 |
--- src/option.c Fri Sep 26 22:20:20 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 2593,2605 ****
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_VIMINFO
|
|
Karsten Hopp |
c85d93 |
(char_u *)&p_viminfo, PV_NONE,
|
|
Karsten Hopp |
c85d93 |
#if defined(MSDOS) || defined(MSWIN) || defined(OS2)
|
|
Karsten Hopp |
c85d93 |
! {(char_u *)"", (char_u *)"'20,<50,s10,h,rA:,rB:"}
|
|
Karsten Hopp |
c85d93 |
#else
|
|
Karsten Hopp |
c85d93 |
# ifdef AMIGA
|
|
Karsten Hopp |
c85d93 |
{(char_u *)"",
|
|
Karsten Hopp |
c85d93 |
! (char_u *)"'20,<50,s10,h,rdf0:,rdf1:,rdf2:"}
|
|
Karsten Hopp |
c85d93 |
# else
|
|
Karsten Hopp |
c85d93 |
! {(char_u *)"", (char_u *)"'20,<50,s10,h"}
|
|
Karsten Hopp |
c85d93 |
# endif
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
#else
|
|
Karsten Hopp |
c85d93 |
--- 2593,2605 ----
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_VIMINFO
|
|
Karsten Hopp |
c85d93 |
(char_u *)&p_viminfo, PV_NONE,
|
|
Karsten Hopp |
c85d93 |
#if defined(MSDOS) || defined(MSWIN) || defined(OS2)
|
|
Karsten Hopp |
c85d93 |
! {(char_u *)"", (char_u *)"'100,<50,s10,h,rA:,rB:"}
|
|
Karsten Hopp |
c85d93 |
#else
|
|
Karsten Hopp |
c85d93 |
# ifdef AMIGA
|
|
Karsten Hopp |
c85d93 |
{(char_u *)"",
|
|
Karsten Hopp |
c85d93 |
! (char_u *)"'100,<50,s10,h,rdf0:,rdf1:,rdf2:"}
|
|
Karsten Hopp |
c85d93 |
# else
|
|
Karsten Hopp |
c85d93 |
! {(char_u *)"", (char_u *)"'100,<50,s10,h"}
|
|
Karsten Hopp |
c85d93 |
# endif
|
|
Karsten Hopp |
c85d93 |
#endif
|
|
Karsten Hopp |
c85d93 |
#else
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/structs.h Thu Jul 31 22:04:27 2008
|
|
Karsten Hopp |
c85d93 |
--- src/structs.h Fri Sep 19 19:15:18 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 459,465 ****
|
|
Karsten Hopp |
c85d93 |
typedef struct
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
int hide; /* TRUE when ":hide" was used */
|
|
Karsten Hopp |
c85d93 |
! # ifdef FEAT_BROWSE
|
|
Karsten Hopp |
c85d93 |
int browse; /* TRUE to invoke file dialog */
|
|
Karsten Hopp |
c85d93 |
# endif
|
|
Karsten Hopp |
c85d93 |
# ifdef FEAT_WINDOWS
|
|
Karsten Hopp |
c85d93 |
--- 459,465 ----
|
|
Karsten Hopp |
c85d93 |
typedef struct
|
|
Karsten Hopp |
c85d93 |
{
|
|
Karsten Hopp |
c85d93 |
int hide; /* TRUE when ":hide" was used */
|
|
Karsten Hopp |
c85d93 |
! # ifdef FEAT_BROWSE_CMD
|
|
Karsten Hopp |
c85d93 |
int browse; /* TRUE to invoke file dialog */
|
|
Karsten Hopp |
c85d93 |
# endif
|
|
Karsten Hopp |
c85d93 |
# ifdef FEAT_WINDOWS
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/vim.h Sat Aug 9 19:37:40 2008
|
|
Karsten Hopp |
c85d93 |
--- src/vim.h Sat Sep 13 17:41:24 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 1728,1734 ****
|
|
Karsten Hopp |
c85d93 |
#define VV_MOUSE_COL 51
|
|
Karsten Hopp |
c85d93 |
#define VV_OP 52
|
|
Karsten Hopp |
c85d93 |
#define VV_SEARCHFORWARD 53
|
|
Karsten Hopp |
c85d93 |
! #define VV_LEN 54 /* number of v: vars */
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_CLIPBOARD
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
--- 1728,1735 ----
|
|
Karsten Hopp |
c85d93 |
#define VV_MOUSE_COL 51
|
|
Karsten Hopp |
c85d93 |
#define VV_OP 52
|
|
Karsten Hopp |
c85d93 |
#define VV_SEARCHFORWARD 53
|
|
Karsten Hopp |
c85d93 |
! #define VV_OLDFILES 54
|
|
Karsten Hopp |
c85d93 |
! #define VV_LEN 55 /* number of v: vars */
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
#ifdef FEAT_CLIPBOARD
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 2054,2057 ****
|
|
Karsten Hopp |
c85d93 |
--- 2055,2064 ----
|
|
Karsten Hopp |
c85d93 |
#define DOSO_VIMRC 1 /* loading vimrc file */
|
|
Karsten Hopp |
c85d93 |
#define DOSO_GVIMRC 2 /* loading gvimrc file */
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
+ /* flags for read_viminfo() and children */
|
|
Karsten Hopp |
c85d93 |
+ #define VIF_WANT_INFO 1 /* load non-mark info */
|
|
Karsten Hopp |
c85d93 |
+ #define VIF_WANT_MARKS 2 /* load file marks */
|
|
Karsten Hopp |
c85d93 |
+ #define VIF_FORCEIT 4 /* overwrite info already read */
|
|
Karsten Hopp |
c85d93 |
+ #define VIF_GET_OLDFILES 8 /* load v:oldfiles */
|
|
Karsten Hopp |
c85d93 |
+
|
|
Karsten Hopp |
c85d93 |
#endif /* VIM__H */
|
|
Karsten Hopp |
c85d93 |
*** ../vim-7.2.030/src/version.c Thu Nov 6 20:47:00 2008
|
|
Karsten Hopp |
c85d93 |
--- src/version.c Sun Nov 9 13:39:19 2008
|
|
Karsten Hopp |
c85d93 |
***************
|
|
Karsten Hopp |
c85d93 |
*** 678,679 ****
|
|
Karsten Hopp |
c85d93 |
--- 678,681 ----
|
|
Karsten Hopp |
c85d93 |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
c85d93 |
+ /**/
|
|
Karsten Hopp |
c85d93 |
+ 31,
|
|
Karsten Hopp |
c85d93 |
/**/
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
--
|
|
Karsten Hopp |
c85d93 |
hundred-and-one symptoms of being an internet addict:
|
|
Karsten Hopp |
c85d93 |
217. Your sex life has drastically improved...so what if it's only cyber-sex!
|
|
Karsten Hopp |
c85d93 |
|
|
Karsten Hopp |
c85d93 |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
c85d93 |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
c85d93 |
\\\ download, build and distribute -- http://www.A-A-P.org ///
|
|
Karsten Hopp |
c85d93 |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|