Skip to content

jrbing/vim-hclfmt

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 

Repository files navigation

vim-hclfmt

Vim plugin to format Hashicorp Configuration Language (HCL) files, using terraform fmt itself.

The plugin by default will format *.hcl, *.tf and *.nomad files on save. Under the hood it uses hclfmt to process the files.

hclfmt

Usage

Save the file or call :HclFmt2.

By default vim-hclfmt automatically formats *.hcl, *.tf and *.nomad files. You can permanently set this configuration in your ~/.vimrc as follows:

let g:hcl_fmt_autosave = 0
let g:tf_fmt_autosave = 0
let g:nomad_fmt_autosave = 0

Install

Vim-hclfmt follows the standard runtime path structure. For Pathogen just clone the repo. For other plugin managers add the appropriate lines and execute the plugin's install command.

  • Pathogen
  • git clone https://github.com/fatih/vim-hclfmt.git ~/.vim/bundle/vim-hclfmt
  • vim-plug
  • Plug 'fatih/vim-hclfmt'
  • NeoBundle
  • NeoBundle 'fatih/vim-hclfmt'
  • Vundle
  • Plugin 'fatih/vim-hclfmt'

About

Vim plugin for hclfmt

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Vim Script 100.0%