diff --git a/.clippy.toml b/.clippy.toml index 7d97bbd98e..851f6fe582 100644 --- a/.clippy.toml +++ b/.clippy.toml @@ -19,5 +19,5 @@ disallowed-types = [ ] disallowed-macros = [ - { path = "std::format", reason = "Use `vite_str::format` for small strings." } + { path = "std::format", reason = "Use `vite_str::format` for small strings." }, ] diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8fe15c3d4a..2e620efbc5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -71,10 +71,11 @@ jobs: with: save-cache: ${{ github.ref_name == 'main' }} cache-key: lint - tools: cargo-shear + tools: dprint,cargo-shear components: clippy rust-docs rustfmt - run: | + dprint check cargo shear cargo fmt --check # cargo clippy --all-targets --all-features -- -D warnings diff --git a/crates/fspy/README.md b/crates/fspy/README.md index c9e3f5bd29..c671d73c1e 100644 --- a/crates/fspy/README.md +++ b/crates/fspy/README.md @@ -16,8 +16,8 @@ For fully static binaries (such as `esbuild`), `LD_PRELOAD` does not work. In th It uses [Detours](https://github.com/microsoft/Detours) to intercept file system calls. The implementation is in `src/windows`. ## Unified interface -The unified interface of `Command` is in `src/command.rs`. +The unified interface of `Command` is in `src/command.rs`. ## Preload Libraries diff --git a/crates/fspy_shared/README.md b/crates/fspy_shared/README.md index b718a4b79f..e240aa9f72 100644 --- a/crates/fspy_shared/README.md +++ b/crates/fspy_shared/README.md @@ -1,3 +1,3 @@ # fspy_shared -Common code shared by `fspy` (run in the supervisor process) and `fspy_preload_*` (run in target processes). +Common code shared by `fspy` (run in the supervisor process) and `fspy_preload_*` (run in target processes). diff --git a/crates/vite_task/docs/vite-install.md b/crates/vite_task/docs/vite-install.md index f7f53cd70d..b64ad4faf7 100644 --- a/crates/vite_task/docs/vite-install.md +++ b/crates/vite_task/docs/vite-install.md @@ -29,9 +29,9 @@ Examples ```yaml packages: - - "packages/*" - - "apps/*" - - "!**/test/**" + - 'packages/*' + - 'apps/*' + - '!**/test/**' ``` /path/to/package.json diff --git a/crates/vite_task/fixtures/cache-sharing/pnpm-workspace.yaml b/crates/vite_task/fixtures/cache-sharing/pnpm-workspace.yaml index ccbac807c1..4de91a383a 100644 --- a/crates/vite_task/fixtures/cache-sharing/pnpm-workspace.yaml +++ b/crates/vite_task/fixtures/cache-sharing/pnpm-workspace.yaml @@ -1,2 +1,2 @@ packages: - - "." + - '.' diff --git a/crates/vite_task/fixtures/comprehensive-task-graph/pnpm-workspace.yaml b/crates/vite_task/fixtures/comprehensive-task-graph/pnpm-workspace.yaml index dee51e928d..18ec407efc 100644 --- a/crates/vite_task/fixtures/comprehensive-task-graph/pnpm-workspace.yaml +++ b/crates/vite_task/fixtures/comprehensive-task-graph/pnpm-workspace.yaml @@ -1,2 +1,2 @@ packages: - - "packages/*" + - 'packages/*' diff --git a/crates/vite_task/fixtures/conflict-test/pnpm-workspace.yaml b/crates/vite_task/fixtures/conflict-test/pnpm-workspace.yaml index dee51e928d..18ec407efc 100644 --- a/crates/vite_task/fixtures/conflict-test/pnpm-workspace.yaml +++ b/crates/vite_task/fixtures/conflict-test/pnpm-workspace.yaml @@ -1,2 +1,2 @@ packages: - - "packages/*" + - 'packages/*' diff --git a/crates/vite_task/fixtures/empty-package-test/pnpm-workspace.yaml b/crates/vite_task/fixtures/empty-package-test/pnpm-workspace.yaml index dee51e928d..18ec407efc 100644 --- a/crates/vite_task/fixtures/empty-package-test/pnpm-workspace.yaml +++ b/crates/vite_task/fixtures/empty-package-test/pnpm-workspace.yaml @@ -1,2 +1,2 @@ packages: - - "packages/*" + - 'packages/*' diff --git a/crates/vite_task/fixtures/explicit-deps-workspace/pnpm-workspace.yaml b/crates/vite_task/fixtures/explicit-deps-workspace/pnpm-workspace.yaml index dee51e928d..18ec407efc 100644 --- a/crates/vite_task/fixtures/explicit-deps-workspace/pnpm-workspace.yaml +++ b/crates/vite_task/fixtures/explicit-deps-workspace/pnpm-workspace.yaml @@ -1,2 +1,2 @@ packages: - - "packages/*" + - 'packages/*' diff --git a/crates/vite_task/fixtures/recursive-topological-workspace/pnpm-workspace.yaml b/crates/vite_task/fixtures/recursive-topological-workspace/pnpm-workspace.yaml index 0e5a0737c3..4e708bd3c5 100644 --- a/crates/vite_task/fixtures/recursive-topological-workspace/pnpm-workspace.yaml +++ b/crates/vite_task/fixtures/recursive-topological-workspace/pnpm-workspace.yaml @@ -1,3 +1,3 @@ packages: - - "packages/*" - - "apps/*" + - 'packages/*' + - 'apps/*' diff --git a/crates/vite_task/fixtures/transitive-dependency-workspace/pnpm-workspace.yaml b/crates/vite_task/fixtures/transitive-dependency-workspace/pnpm-workspace.yaml index dee51e928d..18ec407efc 100644 --- a/crates/vite_task/fixtures/transitive-dependency-workspace/pnpm-workspace.yaml +++ b/crates/vite_task/fixtures/transitive-dependency-workspace/pnpm-workspace.yaml @@ -1,2 +1,2 @@ packages: - - "packages/*" + - 'packages/*' diff --git a/dprint.json b/dprint.json index ad7609991c..4d016d203e 100644 --- a/dprint.json +++ b/dprint.json @@ -13,6 +13,7 @@ "quotes": "preferSingle" }, "excludes": [ + "crates/fspy_detours_sys/detours", "pnpm-lock.yaml", "packages/cli/binding/index.d.ts", "packages/cli/binding/index.js" diff --git a/packages/cli/snap-tests/replay-logs-chronological-order/pnpm-workspace.yaml b/packages/cli/snap-tests/replay-logs-chronological-order/pnpm-workspace.yaml index ccbac807c1..4de91a383a 100644 --- a/packages/cli/snap-tests/replay-logs-chronological-order/pnpm-workspace.yaml +++ b/packages/cli/snap-tests/replay-logs-chronological-order/pnpm-workspace.yaml @@ -1,2 +1,2 @@ packages: - - "." + - '.' diff --git a/packages/cli/snap-tests/workspace-root-vite-config/pnpm-workspace.yaml b/packages/cli/snap-tests/workspace-root-vite-config/pnpm-workspace.yaml index ccbac807c1..4de91a383a 100644 --- a/packages/cli/snap-tests/workspace-root-vite-config/pnpm-workspace.yaml +++ b/packages/cli/snap-tests/workspace-root-vite-config/pnpm-workspace.yaml @@ -1,2 +1,2 @@ packages: - - "." + - '.' diff --git a/packages/global/verdaccio.md b/packages/global/verdaccio.md index 25fddc3e4a..4e20a6a97c 100644 --- a/packages/global/verdaccio.md +++ b/packages/global/verdaccio.md @@ -14,7 +14,7 @@ uplinks: npmjs: url: https://registry.npmjs.org/ packages: - "**": + '**': access: $all publish: $all proxy: npmjs diff --git a/packages/tools/src/json-edit.ts b/packages/tools/src/json-edit.ts index 5af1b8fd37..0fb099c53d 100755 --- a/packages/tools/src/json-edit.ts +++ b/packages/tools/src/json-edit.ts @@ -1,18 +1,18 @@ #!/usr/bin/env node -import { readFileSync, writeFileSync } from 'node:fs' +import { readFileSync, writeFileSync } from 'node:fs'; const filename = process.argv[2]; const script = process.argv[3]; if (!filename || !script) { - console.error('Usage: json-edit