mirror of
https://github.com/numtide/treefmt.git
synced 2024-08-16 20:30:25 +03:00
Update terraform example to remove wrapper
parent
baba0da831
commit
677aa6750c
16
Home.md
16
Home.md
@ -147,18 +147,10 @@ Note that Prettier also supports some other languages through the use of plugins
|
|||||||
|
|
||||||
```
|
```
|
||||||
[formatter.terraform]
|
[formatter.terraform]
|
||||||
# Terraform fmt only takes one file at the time so we create a wrapper.
|
# Careful, only terraform 1.3.0 or later accept a list of files.
|
||||||
# See https://github.com/numtide/treefmt/issues/97
|
# see https://github.com/numtide/treefmt/issues/97
|
||||||
command = "/bin/sh"
|
command = "terraform"
|
||||||
options = [
|
options = ["fmt"]
|
||||||
"-euc",
|
|
||||||
"""
|
|
||||||
for f in "$@"; do
|
|
||||||
terraform fmt "$f"
|
|
||||||
done
|
|
||||||
""",
|
|
||||||
"--",
|
|
||||||
]
|
|
||||||
includes = ["*.tf"]
|
includes = ["*.tf"]
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user