Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fix indent after a word ending in or/and

  • Loading branch information...
commit abfe8602bf038fa26413cff7a1ab8b2e4c65dfb3 1 parent d1cd15d
@tpope tpope authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 indent/ruby.vim
View
4 indent/ruby.vim
@@ -81,12 +81,12 @@ let s:end_skip_expr = s:skip_expr .
\ ' && getline(".") =~ "^\\s*\\<\\(while\\|until\\|for\\):\\@!\\>")'
" Regex that defines continuation lines, not including (, {, or [.
-let s:non_bracket_continuation_regex = '\%([\\.,:*/%+]\|and\|or\|\%(<%\)\@<![=-]\|\W[|&?]\|||\|&&\)\s*\%(#.*\)\=$'
+let s:non_bracket_continuation_regex = '\%([\\.,:*/%+]\|\<and\|\<or\|\%(<%\)\@<![=-]\|\W[|&?]\|||\|&&\)\s*\%(#.*\)\=$'
" Regex that defines continuation lines.
" TODO: this needs to deal with if ...: and so on
let s:continuation_regex =
- \ '\%([({[\\.,:*/%+]\|and\|or\|\%(<%\)\@<![=-]\|\W[|&?]\|||\|&&\)\s*\%(#.*\)\=$'
+ \ '\%([({[\\.,:*/%+]\|\<and\|\<or\|\%(<%\)\@<![=-]\|\W[|&?]\|||\|&&\)\s*\%(#.*\)\=$'
" Regex that defines bracket continuations
let s:bracket_continuation_regex = '\%([({[]\)\s*\%(#.*\)\=$'
Please sign in to comment.
Something went wrong with that request. Please try again.