Mercurial > vim
comparison runtime/ftplugin/vim.vim @ 20552:74e3316c1d5a
Update runtime files
Commit: https://github.com/vim/vim/commit/388a5d4f20b4b64341d1604aa238cab85827b892
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue May 26 21:20:45 2020 +0200
Update runtime files
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Tue, 26 May 2020 21:30:04 +0200 |
parents | 94eda51ba9ba |
children | 59f93c2d2551 |
comparison
equal
deleted
inserted
replaced
20551:f1b23a9643fe | 20552:74e3316c1d5a |
---|---|
1 " Vim filetype plugin | 1 " Vim filetype plugin |
2 " Language: Vim | 2 " Language: Vim |
3 " Maintainer: Bram Moolenaar <Bram@vim.org> | 3 " Maintainer: Bram Moolenaar <Bram@vim.org> |
4 " Last Change: 2018 Aug 07 | 4 " Last Change: 2020 May 17 |
5 | 5 |
6 " Only do this when not done yet for this buffer | 6 " Only do this when not done yet for this buffer |
7 if exists("b:did_ftplugin") | 7 if exists("b:did_ftplugin") |
8 finish | 8 finish |
9 endif | 9 endif |
10 | 10 |
11 " Don't load another plugin for this buffer | 11 " Don't load another plugin for this buffer |
12 let b:did_ftplugin = 1 | 12 let b:did_ftplugin = 1 |
13 | 13 |
14 let s:cpo_save = &cpo | 14 let s:cpo_save = &cpo |
15 set cpo-=C | 15 set cpo&vim |
16 | 16 |
17 if !exists('*VimFtpluginUndo') | 17 if !exists('*VimFtpluginUndo') |
18 func VimFtpluginUndo() | 18 func VimFtpluginUndo() |
19 setl fo< isk< com< tw< commentstring< | 19 setl fo< isk< com< tw< commentstring< |
20 if exists('b:did_add_maps') | 20 if exists('b:did_add_maps') |
61 | 61 |
62 if !exists("no_plugin_maps") && !exists("no_vim_maps") | 62 if !exists("no_plugin_maps") && !exists("no_vim_maps") |
63 let b:did_add_maps = 1 | 63 let b:did_add_maps = 1 |
64 | 64 |
65 " Move around functions. | 65 " Move around functions. |
66 nnoremap <silent><buffer> [[ m':call search('^\s*fu\%[nction]\>', "bW")<CR> | 66 nnoremap <silent><buffer> [[ m':call search('^\s*\(fu\%[nction]\\|def\)\>', "bW")<CR> |
67 vnoremap <silent><buffer> [[ m':<C-U>exe "normal! gv"<Bar>call search('^\s*fu\%[nction]\>', "bW")<CR> | 67 vnoremap <silent><buffer> [[ m':<C-U>exe "normal! gv"<Bar>call search('^\s*\(fu\%[nction]\\|def\)\>', "bW")<CR> |
68 nnoremap <silent><buffer> ]] m':call search('^\s*fu\%[nction]\>', "W")<CR> | 68 nnoremap <silent><buffer> ]] m':call search('^\s*\(fu\%[nction]\\|def\)\>', "W")<CR> |
69 vnoremap <silent><buffer> ]] m':<C-U>exe "normal! gv"<Bar>call search('^\s*fu\%[nction]\>', "W")<CR> | 69 vnoremap <silent><buffer> ]] m':<C-U>exe "normal! gv"<Bar>call search('^\s*\(fu\%[nction]\\|def\)\>', "W")<CR> |
70 nnoremap <silent><buffer> [] m':call search('^\s*endf\%[unction]\>', "bW")<CR> | 70 nnoremap <silent><buffer> [] m':call search('^\s*end\(f\%[unction]\\|def\)\>', "bW")<CR> |
71 vnoremap <silent><buffer> [] m':<C-U>exe "normal! gv"<Bar>call search('^\s*endf\%[unction]\>', "bW")<CR> | 71 vnoremap <silent><buffer> [] m':<C-U>exe "normal! gv"<Bar>call search('^\s*end\(f\%[unction]\\|def\)\>', "bW")<CR> |
72 nnoremap <silent><buffer> ][ m':call search('^\s*endf\%[unction]\>', "W")<CR> | 72 nnoremap <silent><buffer> ][ m':call search('^\s*end\(f\%[unction]\\|def\)\>', "W")<CR> |
73 vnoremap <silent><buffer> ][ m':<C-U>exe "normal! gv"<Bar>call search('^\s*endf\%[unction]\>', "W")<CR> | 73 vnoremap <silent><buffer> ][ m':<C-U>exe "normal! gv"<Bar>call search('^\s*end\(f\%[unction]\\|def\)\>', "W")<CR> |
74 | 74 |
75 " Move around comments | 75 " Move around comments |
76 nnoremap <silent><buffer> ]" :call search('^\(\s*".*\n\)\@<!\(\s*"\)', "W")<CR> | 76 nnoremap <silent><buffer> ]" :call search('^\(\s*".*\n\)\@<!\(\s*"\)', "W")<CR> |
77 vnoremap <silent><buffer> ]" :<C-U>exe "normal! gv"<Bar>call search('^\(\s*".*\n\)\@<!\(\s*"\)', "W")<CR> | 77 vnoremap <silent><buffer> ]" :<C-U>exe "normal! gv"<Bar>call search('^\(\s*".*\n\)\@<!\(\s*"\)', "W")<CR> |
78 nnoremap <silent><buffer> [" :call search('\%(^\s*".*\n\)\%(^\s*"\)\@!', "bW")<CR> | 78 nnoremap <silent><buffer> [" :call search('\%(^\s*".*\n\)\%(^\s*"\)\@!', "bW")<CR> |