Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
185 changes: 181 additions & 4 deletions bun.lock

Large diffs are not rendered by default.

120 changes: 120 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
// Minimal flat config — only the rule we need to track `any` usage.
// Part of the phased `any`-reduction work landing on fix/reduce-any-types.
//
// Note: the repo has many existing `// eslint-disable custom-rules/<name>`
// comments referencing rules from a previous (now-removed) custom plugin.
// We register a stub `custom-rules` plugin whose rules are all "off"; this
// makes the comments valid so eslint doesn't error on unknown rule names.
import tseslint from "@typescript-eslint/eslint-plugin";
import tsparser from "@typescript-eslint/parser";

const DEPRECATED_CUSTOM_RULE_NAMES = [
"bootstrap-isolation",
"no-cross-platform-process-issues",
"no-direct-json-operations",
"no-direct-ps-commands",
"no-lookbehind-regex",
"no-process-cwd",
"no-process-env-top-level",
"no-process-exit",
"no-sync-fs",
"no-top-level-dynamic-import",
"no-top-level-side-effects",
"prefer-use-keybindings",
"prefer-use-terminal-size",
"prompt-spacing",
"require-bun-typeof-guard",
"require-tool-match-name",
"safe-env-boolean-check",
];

// Stub plugin: each rule is a no-op listener so eslint resolves the name
// but does nothing.
const stubRules = Object.fromEntries(
DEPRECATED_CUSTOM_RULE_NAMES.map((name) => [
name,
{
meta: { schema: [], deprecated: true },
create() {
return {};
},
},
]),
);

/** @type {import("eslint").ESLint.Plugin} */
const customRulesPlugin = {
rules: stubRules,
};

// Stub plugin for legacy `eslint-plugin-n/*` references in source comments.
const eslintPluginNPlugin = {
rules: {
"no-unsupported-features/node-builtins": {
meta: { schema: [], deprecated: true },
create() {
return {};
},
},
},
};

// Stub plugin for legacy `react-hooks/*` references in source comments.
const reactHooksPlugin = {
rules: {
"exhaustive-deps": {
meta: { schema: [], deprecated: true },
create() {
return {};
},
},
"rules-of-hooks": {
meta: { schema: [], deprecated: true },
create() {
return {};
},
},
},
};

export default [
{
ignores: [
"dist/**",
"node_modules/**",
"vendor/**",
"web/**",
"vscode-extension/**",
"coverage/**",
"reports/**",
],
},
{
files: ["src/**/*.{ts,tsx}", "tests/**/*.{ts,tsx}", "scripts/**/*.ts"],
languageOptions: {
parser: tsparser,
parserOptions: {
ecmaVersion: 2023,
sourceType: "module",
ecmaFeatures: { jsx: true },
},
},
plugins: {
"@typescript-eslint": tseslint,
"custom-rules": customRulesPlugin,
"eslint-plugin-n": eslintPluginNPlugin,
"react-hooks": reactHooksPlugin,
},
linterOptions: {
// Source has many `// eslint-disable` comments that may now refer to
// rules not enabled here; don't fail on unused directives.
reportUnusedDisableDirectives: "off",
},
rules: {
// Flags both `: any` annotations and `as any` casts.
// warn (not error) so existing code keeps building while we
// surface counts and reduce incrementally.
"@typescript-eslint/no-explicit-any": "warn",
},
},
];
16 changes: 11 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,10 @@
"typecheck:type-tests": "bun run scripts/typecheck-type-tests.ts",
"smoke": "bun run build && node dist/cli.mjs --version",
"deadcode": "knip --include files,dependencies",
"check": "bun run smoke && bun run deadcode && bun run test:full",
"lint": "eslint .",
"lint:any-budget": "bun run scripts/any-usage-report.ts --check",
"check": "bun run lint:any-budget && bun run smoke && bun run deadcode && bun run test:full",
"check:strict": "bun run typecheck && bun run lint && bun run lint:any-budget && bun run smoke && bun run deadcode && bun run test:full",
Comment thread
jatmn marked this conversation as resolved.
"verify:privacy": "bun run scripts/verify-no-phone-home.ts",
"install:verify": "bun run scripts/verify-clean-install.ts",
"install:verify:published": "bun run scripts/verify-clean-install.ts --published",
Expand All @@ -86,7 +89,6 @@
"devDependencies": {
"@alcalzone/ansi-tokenize": "0.3.0",
"@anthropic-ai/bedrock-sdk": "0.29.1",
"@sentry/node": "^10.70.0",
"@anthropic-ai/foundry-sdk": "0.2.3",
"@anthropic-ai/sandbox-runtime": "0.0.55",
"@anthropic-ai/sdk": "0.94.0",
Expand All @@ -98,11 +100,14 @@
"@grpc/grpc-js": "^1.14.3",
"@grpc/proto-loader": "^0.8.0",
"@modelcontextprotocol/sdk": "1.29.0",
"@sentry/node": "^10.70.0",
"@smithy/core": "3.24.3",
"@smithy/node-http-handler": "4.7.3",
"@types/bun": "1.3.11",
"@types/node": "25.5.0",
"@types/react": "19.2.14",
"@typescript-eslint/eslint-plugin": "^8.69.0",
"@typescript-eslint/parser": "^8.69.0",
"ajv": "8.18.0",
"auto-bind": "5.0.1",
"axios": "1.16.0",
Expand All @@ -117,16 +122,17 @@
"duck-duck-scrape": "^2.2.7",
"emoji-regex": "10.6.0",
"env-paths": "3.0.0",
"eslint": "9.39.5",
"execa": "9.6.1",
"fflate": "0.8.2",
"figures": "6.1.0",
"fuse.js": "7.1.0",
"graphology": "0.26.0",
"get-east-asian-width": "1.5.0",
"google-auth-library": "10.6.2",
"graphology": "0.26.0",
"graphology-metrics": "2.4.0",
"https-proxy-agent": "7.0.6",
"ignore": "7.0.5",
"graphology-metrics": "2.4.0",
"indent-string": "5.0.0",
"js-tiktoken": "1.0.21",
"jsonc-parser": "3.3.1",
Expand All @@ -153,8 +159,8 @@
"typescript": "5.9.3",
"undici": "7.28.0",
"usehooks-ts": "3.1.1",
"web-tree-sitter": "0.25.10",
"vscode-languageserver-protocol": "3.17.5",
"web-tree-sitter": "0.25.10",
"wrap-ansi": "9.0.2",
"ws": "8.21.0",
"xss": "1.0.15",
Expand Down
4 changes: 4 additions & 0 deletions reports/any-usage.baseline.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"total": 779,
"generatedAt": "2026-09-06T02:24:17.929Z"
}
Loading
Loading