Skip to content

Commit 73ea6e2

Browse files
committed
fix(lint): clean lint debt + repair import paths
`pnpm run check --all` now passes 0 errors (lint + TypeScript). `pnpm vitest run test/unit/packages/edit.test.mts` passes 83/83 tests (the pkgJsonToEditable concern was already resolved). - scripts/util/run-command.mts, scripts/lint.mts, scripts/util/changed-test-mapper.mts: socket-lib's package `exports` map uses granular paths (./spawn/spawn, ./argv/flag- predicates, ./git/changed, ./git/staged) — not the consumer- facing barrels (./spawn, ./argv/flags, ./git). The cascaded wheelhouse scripts assumed barrels; rewrote imports to match socket-lib's actual exports. - bulk import rewrite across 23 scripts/ files: `from '@socketsecurity/lib/spawn'` → `from '@socketsecurity/lib/spawn/ spawn'`; `from '@socketsecurity/lib/argv/flags'` → `from '@socketsecurity/lib/argv/flag-predicates'` - .config/vitest.config.mts + .config/vitest.config.isolated.mts: the earlier catalog-rename sed produced a duplicate `@socketsecurity/lib` key (one each from `lib` and `lib-stable` → both becoming `lib`); de-duplicated. - 65 files autofixed by oxlint --fix (export-top-level-functions, sort-source-methods, etc.)
1 parent 4b06e3d commit 73ea6e2

66 files changed

Lines changed: 1137 additions & 965 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.config/oxlint-plugin/lib/rule-tester.mts

Lines changed: 3 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.config/oxlint-plugin/rules/no-logger-newline-literal.mts

Lines changed: 8 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.config/oxlint-plugin/test/inclusive-language.test.mts

Lines changed: 8 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.config/oxlint-plugin/test/no-logger-newline-literal.test.mts

Lines changed: 48 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.config/oxlint-plugin/test/no-placeholders.test.mts

Lines changed: 8 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.config/oxlint-plugin/test/no-promise-race.test.mts

Lines changed: 8 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.config/oxlint-plugin/test/personal-path-placeholders.test.mts

Lines changed: 4 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.config/oxlint-plugin/test/prefer-node-builtin-imports.test.mts

Lines changed: 8 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.config/vitest.config.isolated.mts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,8 @@ const vitestConfigIsolated = defineConfig({
3434
'fast-sort': path.resolve(projectRoot, 'src/external/fast-sort'),
3535
pacote: path.resolve(projectRoot, 'src/external/pacote'),
3636
'@socketregistry/scripts': path.resolve(projectRoot, 'scripts'),
37-
// Both names resolve to src/ — `lib` is the canonical published
38-
// name, `lib-stable` is the fleet-wide infra alias.
39-
'@socketsecurity/lib': path.resolve(projectRoot, 'src'),
37+
// Resolve `@socketsecurity/lib` to local src/ so test files don't
38+
// pull in the published version through the pnpm overrides block.
4039
'@socketsecurity/lib': path.resolve(projectRoot, 'src'),
4140
},
4241
},

.config/vitest.config.mts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,8 @@ const vitestConfig = defineConfig({
4141
'fast-sort': path.resolve(projectRoot, 'src/external/fast-sort'),
4242
pacote: path.resolve(projectRoot, 'src/external/pacote'),
4343
'@socketregistry/scripts': path.resolve(projectRoot, 'scripts'),
44-
// Both names resolve to src/ — `lib` is the canonical published
45-
// name, `lib-stable` is the fleet-wide infra alias.
46-
'@socketsecurity/lib': path.resolve(projectRoot, 'src'),
44+
// Resolve `@socketsecurity/lib` to local src/ so test files don't
45+
// pull in the published version through the pnpm overrides block.
4746
'@socketsecurity/lib': path.resolve(projectRoot, 'src'),
4847
},
4948
},

0 commit comments

Comments
 (0)