diff options
author | Adam Stankiewicz <sheerun@sher.pl> | 2019-03-04 09:15:44 +0100 |
---|---|---|
committer | Adam Stankiewicz <sheerun@sher.pl> | 2019-03-04 09:15:44 +0100 |
commit | ed677c34d55a0e025b7008f29419498a3989cde2 (patch) | |
tree | 62efef78ed05b2b4e61efb21e40a6b337359eb8e /ftplugin/terraform.vim | |
parent | c161994e9607399a7b365ab274592bfc4f100306 (diff) | |
download | vim-polyglot-ed677c34d55a0e025b7008f29419498a3989cde2.tar.gz vim-polyglot-ed677c34d55a0e025b7008f29419498a3989cde2.zip |
Update
Diffstat (limited to 'ftplugin/terraform.vim')
-rw-r--r-- | ftplugin/terraform.vim | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/ftplugin/terraform.vim b/ftplugin/terraform.vim index bbebacbc..c5c30627 100644 --- a/ftplugin/terraform.vim +++ b/ftplugin/terraform.vim @@ -3,6 +3,8 @@ if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'terraform') == " terraform.vim - basic vim/terraform integration " Maintainer: HashiVim <https://github.com/hashivim> +set formatoptions-=t + if exists("g:loaded_terraform") || v:version < 700 || &cp || !executable('terraform') finish endif @@ -44,7 +46,7 @@ endfunction " https://github.com/fatih/vim-hclfmt/blob/master/autoload/fmt.vim function! terraform#fmt() let l:curw = winsaveview() - let l:tmpfile = tempname() + let l:tmpfile = tempname() . ".tf" call writefile(getline(1, "$"), l:tmpfile) let output = system("terraform fmt -write " . l:tmpfile) if v:shell_error == 0 |