diff --git a/.changeset/drop-per-package-lint-scripts.md b/.changeset/drop-per-package-lint-scripts.md new file mode 100644 index 0000000000..189d06d9ea --- /dev/null +++ b/.changeset/drop-per-package-lint-scripts.md @@ -0,0 +1,4 @@ +--- +--- + +fix(dx): remove the per-package `lint` scripts (`eslint src`) from `@objectstack/verify`, `@objectstack/cli` and `@objectstack/lint` (#4276). A standalone run resolves the root flat config but honors the inline directives the root gate's `--no-inline-config` exists to ignore, so it fails on rules the config never registers — verify was red on a clean HEAD. Lint only from the root; the scoped recipe is documented in `eslint.config.mjs`. Dev scripts only; releases nothing. diff --git a/eslint.config.mjs b/eslint.config.mjs index 8740323df1..e0ab1292c6 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -18,6 +18,13 @@ import tsParser from '@typescript-eslint/parser'; // import guard), and the flag ignores them so the guard runs clean. The only // active rule (no-restricted-imports) should never need a local opt-out — it // prevents a ~1.2GB RSS regression. +// +// Lint ONLY from the root. Per-package `lint` scripts (`eslint src`) were +// removed in #4276: a standalone run resolves this same config but honors the +// inline directives `--no-inline-config` exists to ignore, so it fails on +// rules this config never registers ("Definition for rule … was not found"). +// Don't add such a script back — scope a local run from the root instead: +// `pnpm exec eslint --no-inline-config packages/verify/src`. const SUBPATH_NAMES = [ 'Data', 'UI', 'System', 'AI', 'API', 'Automation', diff --git a/packages/cli/package.json b/packages/cli/package.json index 7675ceaf00..5bec4a9a13 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -11,8 +11,7 @@ "scripts": { "build": "if [ -n \"$OS_SKIP_DTS\" ]; then tsc -p tsconfig.build.json --noCheck --declaration false --declarationMap false; else tsc -p tsconfig.build.json; fi", "dev": "tsc -p tsconfig.build.json --watch", - "test": "vitest run", - "lint": "eslint src" + "test": "vitest run" }, "keywords": [ "objectstack", diff --git a/packages/lint/package.json b/packages/lint/package.json index 48e967f4e4..0a7f1843bd 100644 --- a/packages/lint/package.json +++ b/packages/lint/package.json @@ -16,7 +16,6 @@ "scripts": { "build": "tsup --config ../../tsup.config.ts", "dev": "tsc -w", - "lint": "eslint src", "test": "vitest run" }, "dependencies": { diff --git a/packages/verify/package.json b/packages/verify/package.json index 6f44df9025..ba2c2789f8 100644 --- a/packages/verify/package.json +++ b/packages/verify/package.json @@ -16,7 +16,6 @@ "scripts": { "build": "tsup --config ../../tsup.config.ts", "dev": "tsc -w", - "lint": "eslint src", "test": "vitest run" }, "dependencies": {