From e63a87718c6edddf20a09314c79afdddf5babc9a Mon Sep 17 00:00:00 2001 From: Gregory Schier Date: Tue, 1 Sep 2026 07:40:42 -0700 Subject: [PATCH] fix(tooling): keep the formatter off generated files in every entry point (#615) Co-authored-by: Claude Opus 5 --- .oxfmtignore | 3 --- package.json | 2 +- vite.config.ts | 17 ++++++++++++++++- 3 files changed, 17 insertions(+), 5 deletions(-) delete mode 100644 .oxfmtignore diff --git a/.oxfmtignore b/.oxfmtignore deleted file mode 100644 index 0dca30df..00000000 --- a/.oxfmtignore +++ /dev/null @@ -1,3 +0,0 @@ -**/bindings/** -**/routeTree.gen.ts -crates/yaak-templates/pkg/** diff --git a/package.json b/package.json index a00186a4..3f7c267f 100644 --- a/package.json +++ b/package.json @@ -100,7 +100,7 @@ "lint:vp": "vp lint", "lint:workspaces": "npm run --workspaces --if-present lint", "replace-version": "node scripts/replace-version.cjs", - "format": "vp fmt --ignore-path .oxfmtignore", + "format": "vp fmt", "tauri": "tauri", "client:tauri-before-build": "npm run bootstrap", "client:tauri-before-dev": "node scripts/run-workspaces-dev.mjs apps/yaak-client", diff --git a/vite.config.ts b/vite.config.ts index 5042e3e1..52b943da 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -4,8 +4,23 @@ export default defineConfig({ staged: { "*": "vp check --fix", }, + // Generated output, reformatted only to be undone by the next regen. Read by every formatter + // entry point, including the `staged` task above. + fmt: { + ignorePatterns: [ + "**/bindings/**", + "**/routeTree.gen.ts", + "crates/yaak-templates/pkg/**", + "crates/yaak-wasm/pkg/**", + ], + }, lint: { - ignorePatterns: ["npm/**", "crates/yaak-templates/pkg/**", "crates/yaak-wasm/pkg/**", "**/bindings/gen_*.ts"], + ignorePatterns: [ + "npm/**", + "crates/yaak-templates/pkg/**", + "crates/yaak-wasm/pkg/**", + "**/bindings/gen_*.ts", + ], options: { typeAware: true, },