summaryrefslogtreecommitdiff
path: root/runtime/indent/rst.vim
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2005-06-29 22:40:58 +0000
committerBram Moolenaar <Bram@vim.org>2005-06-29 22:40:58 +0000
commit42eeac3552c5a5ea10f24373f76b93633b6c8604 (patch)
tree902f3158470a3e9c53850708cf982c85c6338796 /runtime/indent/rst.vim
parent24bbcfe8fe62ea43b1cea86243be4fdc8794140b (diff)
downloadvim-git-42eeac3552c5a5ea10f24373f76b93633b6c8604.tar.gz
updated for version 7.0097v7.0097
Diffstat (limited to 'runtime/indent/rst.vim')
-rw-r--r--runtime/indent/rst.vim18
1 files changed, 5 insertions, 13 deletions
diff --git a/runtime/indent/rst.vim b/runtime/indent/rst.vim
index c6269ec6a..f98e7556d 100644
--- a/runtime/indent/rst.vim
+++ b/runtime/indent/rst.vim
@@ -1,28 +1,22 @@
" Vim indent file
-" Language: reStructuredText Documentation Format
-" Maintainer: Nikolai Weibull <source@pcppopper.org>
-" URL: http://www.pcppopper.org/vim/indent/pcp/rst/
-" Latest Revision: 2004-04-25
-" arch-tag: 3fe10f75-24d0-4d94-a924-0ce945958104
+" Language: reStructuredText Documentation Format
+" Maintainer: Nikolai Weibull <nikolai+work.vim@bitwi.se>
+" Latest Revision: 2005-06-29
-" Only load this indent file when no other was loaded.
if exists("b:did_indent")
finish
endif
-
let b:did_indent = 1
setlocal indentexpr=GetRSTIndent()
-setlocal indentkeys-=:,0# indentkeys-=e
+setlocal indentkeys=!^F,o,O
-" Only define the function once.
if exists("*GetRSTIndent")
finish
endif
function GetRSTIndent()
let lnum = prevnonblank(v:lnum - 1)
-
if lnum == 0
return 0
endif
@@ -46,7 +40,7 @@ function GetRSTIndent()
let ind = ind - 2
elseif line =~ '^\s*\d\+\.\s'
let ind = ind - matchend(substitute(line, '^\s*', '', ''),
- \ '\d\+\.\s\+')
+ \ '\d\+\.\s\+')
elseif line =~ '^\s*\.\.'
let ind = ind - 3
else
@@ -56,5 +50,3 @@ function GetRSTIndent()
return ind
endfunction
-
-" vim: set sts=2 sw=2: