summaryrefslogtreecommitdiffstats
path: root/indent/puppet.vim
diff options
context:
space:
mode:
authorAdam Stankiewicz <sheerun@sher.pl>2014-08-12 23:45:36 +0200
committerAdam Stankiewicz <sheerun@sher.pl>2014-08-12 23:45:36 +0200
commit90b24287deb9da69a8079599b8525e2be412f7f2 (patch)
tree78225d68b68f45ffa55d9fc84b10e64941abf96a /indent/puppet.vim
parent5f1223fbc5285689db812236c9100329740a805b (diff)
downloadvim-polyglot-90b24287deb9da69a8079599b8525e2be412f7f2.tar.gz
vim-polyglot-90b24287deb9da69a8079599b8525e2be412f7f2.zip
Update
Diffstat (limited to 'indent/puppet.vim')
-rw-r--r--indent/puppet.vim13
1 files changed, 13 insertions, 0 deletions
diff --git a/indent/puppet.vim b/indent/puppet.vim
index 56ee46d5..cf49de88 100644
--- a/indent/puppet.vim
+++ b/indent/puppet.vim
@@ -76,6 +76,19 @@ function! GetPuppetIndent()
if line =~ '^\s*}\s*els\(e\|if\).*{\s*$'
let ind -= &sw
endif
+
+ " Don't indent resources that are one after another with a ->(ordering arrow)
+ " file {'somefile':
+ " ...
+ " } ->
+ "
+ " package { 'mycoolpackage':
+ " ...
+ " }
+ if line =~ '->$'
+ let ind -= &sw
+ endif
+
return ind
endfunction