diff options
author | Bram Moolenaar <Bram@vim.org> | 2008-06-24 20:39:31 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2008-06-24 20:39:31 +0000 |
commit | a7241f5f19fd0865ce697939c347a8c88fb507d5 (patch) | |
tree | e1f1c07fe74094539286be048cc3306f6aedb0bc /runtime/spell | |
parent | f233048a129fa7a3b89e064078435181d6421da5 (diff) | |
download | vim-git-a7241f5f19fd0865ce697939c347a8c88fb507d5.tar.gz |
updated for version 7.2a
Diffstat (limited to 'runtime/spell')
-rw-r--r-- | runtime/spell/cleanadd.vim | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/runtime/spell/cleanadd.vim b/runtime/spell/cleanadd.vim index cb7620fbf..6dc069218 100644 --- a/runtime/spell/cleanadd.vim +++ b/runtime/spell/cleanadd.vim @@ -1,6 +1,6 @@ " Vim script to clean the ll.xxxxx.add files of commented out entries " Author: Antonio Colombo, Bram Moolenaar -" Last Update: 2006 Jan 19 +" Last Update: 2008 Jun 3 " Time in seconds after last time an ll.xxxxx.add file was updated " Default is one second. @@ -14,12 +14,19 @@ endif " Delete all comment lines, except the ones starting with ##. for s:fname in split(globpath(&rtp, "spell/*.add"), "\n") if filewritable(s:fname) && localtime() - getftime(s:fname) > g:spell_clean_limit - silent exe "tab split " . escape(s:fname, ' \') - echo "Processing" s:fname + if exists('*fnameescape') + let s:f = fnameescape(s:fname) + else + let s:f = escape(s:fname, ' \|<') + endif + silent exe "tab split " . s:f + echo "Processing" s:f silent! g/^#[^#]/d silent update close + unlet s:f endif endfor +unlet s:fname echo "Done" |