Skip to content

Commit

Permalink
Work around regression of treefmt that only formats first file path
Browse files Browse the repository at this point in the history
  • Loading branch information
evolutics committed Oct 27, 2024
1 parent 4af3f18 commit 945c901
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,5 +90,5 @@ The following tools are integrated:
- [**treefmt**](https://github.com/numtide/treefmt)

```bash
treefmt --fail-on-change --no-cache *.bzl *.cjs *.clj *.cljc *.cljs *.cljx *.css *.html *.js *.json *.json5 *.jsonnet *.jsx *.libsonnet *.md *.mdx *.mjs *.nix *.py *.pyi *.rb *.scss *.sh *.tf *.toml *.ts *.tsx *.vue *.yaml *.yml BUILD.bazel Vagrantfile
treefmt --fail-on-change --no-cache --walk filesystem *.bzl *.cjs *.clj *.cljc *.cljs *.cljx *.css *.html *.js *.json *.json5 *.jsonnet *.jsx *.libsonnet *.md *.mdx *.mjs *.nix *.py *.pyi *.rb *.scss *.sh *.tf *.toml *.ts *.tsx *.vue *.yaml *.yml BUILD.bazel Vagrantfile
```
2 changes: 2 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@
"${treefmtEval.config.build.wrapper}/bin/treefmt"
"--fail-on-change"
"--no-cache"
"--walk"
"filesystem"
# `"--"` would break treefmt as it seems to append `--tree-root`.
];
file_patterns = let
Expand Down
2 changes: 1 addition & 1 deletion test/expected_calls.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ Would run: /…/jsonnet-lint -- jsonnet_lint.jsonnet jsonnetfmt.jsonnet
Would run: /…/pylint -- black.py isort.py pylint.py
Would run: /…/shellcheck -- shellcheck.sh shfmt.sh
Would run: /…/stylelint -- stylelint.css
Would run: /…/treefmt --fail-on-change --no-cache Vagrantfile alejandra.nix black.py buildifier.bzl cljfmt.clj isort.py jsonnet_lint.jsonnet jsonnetfmt.jsonnet prettier.js prettier.toml pylint.py rufo.rb shellcheck.sh shfmt.sh statix.nix stylelint.css terraform.tf
Would run: /…/treefmt --fail-on-change --no-cache --walk filesystem Vagrantfile alejandra.nix black.py buildifier.bzl cljfmt.clj isort.py jsonnet_lint.jsonnet jsonnetfmt.jsonnet prettier.js prettier.toml pylint.py rufo.rb shellcheck.sh shfmt.sh statix.nix stylelint.css terraform.tf

0 comments on commit 945c901

Please sign in to comment.