aboutsummaryrefslogtreecommitdiff
path: root/vim/plugin
diff options
context:
space:
mode:
Diffstat (limited to 'vim/plugin')
-rw-r--r--vim/plugin/paste_insert.vim2
-rw-r--r--vim/plugin/put_date.vim6
-rw-r--r--vim/plugin/select_old_files.vim8
-rw-r--r--vim/plugin/spellfile_local.vim13
-rw-r--r--vim/plugin/utc.vim6
5 files changed, 12 insertions, 23 deletions
diff --git a/vim/plugin/paste_insert.vim b/vim/plugin/paste_insert.vim
index 9cd5415e..2c17f802 100644
--- a/vim/plugin/paste_insert.vim
+++ b/vim/plugin/paste_insert.vim
@@ -1,4 +1,4 @@
-if exists('loaded_paste_insert')
+if exists('loaded_paste_insert') || &compatible
finish
endif
let loaded_paste_insert = 1
diff --git a/vim/plugin/put_date.vim b/vim/plugin/put_date.vim
index d911486e..e78f5fcd 100644
--- a/vim/plugin/put_date.vim
+++ b/vim/plugin/put_date.vim
@@ -1,6 +1,6 @@
-if exists('loaded_put_date')
+if exists('loaded_put_date') || &compatible || !has('*strftime')
finish
endif
let loaded_put_date = 1
-command! -bar -range PutDate
- \ <line1>put =strftime('%a, %d %b %Y %T %z')
+command! -bang -bar -nargs=* -range PutDate
+ \ call put_date#(<q-line1>, <q-bang> ==# '!', <q-args>)
diff --git a/vim/plugin/select_old_files.vim b/vim/plugin/select_old_files.vim
index dbfbd64c..77c7746e 100644
--- a/vim/plugin/select_old_files.vim
+++ b/vim/plugin/select_old_files.vim
@@ -1,6 +1,8 @@
-if exists('loaded_select_old_files')
+if exists('loaded_select_old_files') || &compatible || !exists(':oldfiles')
finish
endif
let loaded_select_old_files = 1
-command! -bar SelectOldFiles
- \ call select_old_files#()
+command! -bar -nargs=? SelectOldFiles
+ \ call select_old_files#(<f-args>)
+nnoremap <Plug>SelectOldFiles
+ \ :<C-U>SelectOldFiles<CR>
diff --git a/vim/plugin/spellfile_local.vim b/vim/plugin/spellfile_local.vim
index c026d626..f6918bfb 100644
--- a/vim/plugin/spellfile_local.vim
+++ b/vim/plugin/spellfile_local.vim
@@ -1,19 +1,12 @@
-if exists('loaded_spellfile_local')
+if exists('loaded_spellfile_local') || &compatible
finish
endif
let loaded_spellfile_local = 1
-let s:spellfile = join([
- \ substitute(v:lang, '_.*', '', ''),
- \ &encoding
- \ ], '.') . '.add'
-Establish $MYVIM/cache/spell
-execute 'set spellfile=$MYVIM/cache/spell/'.s:spellfile
-
-command! -bar AddLocalSpellFile
+command! -bar SetLocalSpellFiles
\ call spellfile_local#()
augroup spellfile_local
autocmd BufNew,BufRead *
- \ AddLocalSpellFile
+ \ SetLocalSpellFiles
augroup END
diff --git a/vim/plugin/utc.vim b/vim/plugin/utc.vim
deleted file mode 100644
index 9b8b647a..00000000
--- a/vim/plugin/utc.vim
+++ /dev/null
@@ -1,6 +0,0 @@
-if exists('loaded_utc')
- finish
-endif
-let loaded_utc = 1
-command! -bar -complete=command -nargs=1 UTC
- \ call utc#(<q-args>)