Format and prettify HCL files
Switch branches/tags
Nothing to show
Clone or download
fatih Merge pull request #8 from chrw/atom-hclfmt
Add atom-hclfmt package to
Latest commit e715913 Aug 24, 2016
Failed to load latest commit information.
.travis.yml Add .travis.yml Nov 2, 2015
LICENSE BSD 3-Clause license Oct 25, 2015 Add atom-hclfmt package to Aug 24, 2016
main.go Make the -w flag behave as expected Mar 15, 2016

hclfmt Build Status

hclfmt is a command to format and prettify HCL files. It's similar to the popular gofmt command. Hook it with your favourite editor or use it from the command line.


If you have Go installed just do:

go get

Editor integration


The usage is similar to gofmt. If you pass a file it prints the formatted output to std output:

$ hclfmt config.hcl

You can pass the -w flag to directly overwrite your file:

$ hclfmt -w config.hcl

If no arguments are passed, it excepts the input from standard input.


The BSD 3-Clause License - see LICENSE for more details