summaryrefslogtreecommitdiffstats
path: root/indent/puppet.vim
diff options
context:
space:
mode:
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