blob: 14eb83a110fc20f317d13ee2b72a4de9db329476 [file] [log] [blame]
Bram Moolenaar28c258f2006-01-25 22:02:51 +00001" Vim script to clean the ll.xxxxx.add files of commented out entries
2" Author: Antonio Colombo, Bram Moolenaar
3" Last Update: 2006 Jan 19
4
5" Time in seconds after last time an ll.xxxxx.add file was updated
6" Default is one hour.
7if !exists("g:spell_clean_limit")
8 let g:spell_clean_limit = 60 * 60
9endif
10
11" Loop over all the runtime/spell/*.add files.
12for s:fname in split(globpath(&rtp, "spell/*.add"), "\n")
13 if filewritable(s:fname) && localtime() - getftime(s:fname) > g:spell_clean_limit
14 silent exe "split " . escape(s:fname, ' \')
15 echo "Processing" s:fname
16 silent! g/^#/d
17 silent update
18 close
19 endif
20endfor
21
22echo "Done"