runtime(hcl,terraform): Add runtime files for HCL and Terraform

closes: #15618

Signed-off-by: Gregory Anders <greg@gpanders.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
Gregory Anders
2024-09-04 22:19:45 +02:00
committed by Christian Brabandt
parent 315b6f7b73
commit 150b5078ac
7 changed files with 166 additions and 0 deletions

16
runtime/indent/hcl.vim Normal file
View File

@ -0,0 +1,16 @@
" Vim indent file
" Language: HCL
" Maintainer: Gregory Anders
" Upstream: https://github.com/hashivim/vim-terraform
" Last Change: 2024-09-03
if exists('b:did_indent')
finish
endif
let b:did_indent = 1
setlocal autoindent shiftwidth=2 tabstop=2 softtabstop=2 expandtab
setlocal indentexpr=hcl#indentexpr(v:lnum)
setlocal indentkeys+=<:>,0=},0=)
let b:undo_indent = 'setlocal ai< sw< ts< sts< et< inde< indk<'

View File

@ -0,0 +1,11 @@
" Vim indent file
" Language: Terraform
" Maintainer: Gregory Anders
" Upstream: https://github.com/hashivim/vim-terraform
" Last Change: 2024-09-03
if exists('b:did_indent')
finish
endif
runtime! indent/hcl.vim