Skip to content

Commit d0370a8

Browse files
logaretmclaude
andauthored
chore: Clean up lint and format script names (#19719)
## Summary Standardize lint/format script naming across the monorepo (53 files). Removes redundant/confusing scripts and makes naming consistent. ### New root-level scripts | Script | Command | Purpose | |--------|---------|---------| | `verify` | `run-s format:check lint` | Read-only: format check + lint | | `fix` | `run-s format lint:fix` | Write: format + lint fix | | `lint` | `oxlint . --type-aware` | Lint only | | `lint:fix` | `oxlint . --fix --type-aware` | Lint + fix only | | `format` | `oxfmt . --write` | Format only | | `format:check` | `oxfmt . --check` | Format check only | ### What changed - `lint` now runs only oxlint (previously also ran oxfmt check) - `lint:fix` replaces old `fix` for oxlint auto-fix - New `verify` runs both `format:check` + `lint` (replaces old `lint` behavior) - New `fix` runs both `format` + `lint:fix` - All oxlint commands consistently include `OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS` flag and `--type-aware` across root and all sub-packages - Removes redundant scripts: `fix:oxlint`, `fix:oxfmt`, `lint:oxfmt`, `lint:oxlint` - Updates CI workflow (`build.yml`) to use new script names ## Test plan - [ ] CI lint job passes with `yarn lint` instead of `yarn lint:oxlint` - [ ] CI format check job passes (unchanged `yarn format:check`) - [ ] `yarn verify` runs both format check and lint at root level - [ ] `yarn fix` runs both format and lint fix at root level 🤖 Generated with [Claude Code](https://claude.com/claude-code) Closes #19722 (added automatically) --------- Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 62d3436 commit d0370a8

File tree

53 files changed

+114
-115
lines changed

Some content is hidden

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

53 files changed

+114
-115
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,7 @@ jobs:
308308
with:
309309
dependency_cache_key: ${{ needs.job_build.outputs.dependency_cache_key }}
310310
- name: Lint source files
311-
run: yarn lint:oxlint
311+
run: yarn lint
312312
- name: Lint for ES compatibility
313313
run: yarn lint:es-compatibility
314314

AGENTS.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,12 @@ Use **yarn**: `yarn install`, `yarn build:dev`, `yarn test`, `yarn lint`
2020
| `yarn build:dev:filter @sentry/<pkg>` | Build one package + deps |
2121
| `yarn build:bundle` | Browser bundles only |
2222
| `yarn test` | All unit tests |
23-
| `yarn lint` | Oxlint + Oxfmt |
24-
| `yarn fix` | Auto-fix lint + format |
25-
| `yarn format` | Auto-fix formatting (Oxfmt) |
23+
| `yarn verify` | Lint + format check |
24+
| `yarn fix` | Format + lint fix |
25+
| `yarn lint` | Lint (Oxlint) |
26+
| `yarn lint:fix` | Lint + auto-fix (Oxlint) |
27+
| `yarn format` | Format files (Oxfmt) |
28+
| `yarn format:check` | Check formatting (Oxfmt) |
2629

2730
Single package: `cd packages/<name> && yarn test`
2831

dev-packages/browser-integration-tests/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
"scripts": {
1111
"clean": "rimraf -g suites/**/dist loader-suites/**/dist tmp",
1212
"install-browsers": "[[ -z \"$SKIP_PLAYWRIGHT_BROWSER_INSTALL\" ]] && npx playwright install --with-deps || echo 'Skipping browser installation'",
13-
"lint": "oxlint .",
14-
"fix": "oxlint . --fix",
13+
"lint": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --type-aware",
14+
"lint:fix": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --fix --type-aware",
1515
"type-check": "tsc",
1616
"postinstall": "yarn install-browsers",
1717
"pretest": "yarn clean && yarn type-check",

dev-packages/clear-cache-gh-action/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
"main": "index.mjs",
1111
"type": "module",
1212
"scripts": {
13-
"lint": "oxlint .",
14-
"fix": "oxlint . --fix"
13+
"lint": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --type-aware",
14+
"lint:fix": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --fix --type-aware"
1515
},
1616
"dependencies": {
1717
"@actions/core": "1.10.1",

dev-packages/cloudflare-integration-tests/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
},
88
"private": true,
99
"scripts": {
10-
"lint": "oxlint .",
11-
"fix": "oxlint . --fix",
10+
"lint": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --type-aware",
11+
"lint:fix": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --fix --type-aware",
1212
"test": "vitest run",
1313
"test:watch": "yarn test --watch"
1414
},

dev-packages/e2e-tests/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
"license": "MIT",
55
"private": true,
66
"scripts": {
7-
"fix": "oxlint . --fix",
8-
"lint": "oxlint .",
7+
"lint:fix": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --fix --type-aware",
8+
"lint": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --type-aware",
99
"lint:ts": "tsc --noEmit",
1010
"test:e2e": "run-s test:validate-configuration test:validate-test-app-setups test:run",
1111
"test:run": "ts-node run.ts",

dev-packages/external-contributor-gh-action/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
"main": "index.mjs",
1111
"type": "module",
1212
"scripts": {
13-
"lint": "oxlint .",
14-
"fix": "oxlint . --fix"
13+
"lint": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --type-aware",
14+
"lint:fix": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --fix --type-aware"
1515
},
1616
"dependencies": {
1717
"@actions/core": "1.10.1"

dev-packages/node-core-integration-tests/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616
"build:types": "tsc -p tsconfig.types.json",
1717
"clean": "rimraf -g **/node_modules && run-p clean:script",
1818
"clean:script": "node scripts/clean.js",
19-
"lint": "oxlint .",
20-
"fix": "oxlint . --fix",
19+
"lint": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --type-aware",
20+
"lint:fix": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --fix --type-aware",
2121
"type-check": "tsc",
2222
"test": "vitest run",
2323
"test:watch": "yarn test --watch"

dev-packages/node-integration-tests/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616
"build:types": "tsc -p tsconfig.types.json",
1717
"clean": "rimraf -g suites/**/node_modules suites/**/tmp_* && run-p clean:script",
1818
"clean:script": "node scripts/clean.js",
19-
"lint": "oxlint .",
20-
"fix": "oxlint . --fix",
19+
"lint": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --type-aware",
20+
"lint:fix": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --fix --type-aware",
2121
"type-check": "tsc",
2222
"test": "vitest run",
2323
"test:watch": "yarn test --watch"

dev-packages/node-overhead-gh-action/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
"clean": "rimraf -g **/node_modules",
2020
"db:up": "docker compose up",
2121
"db:down": "docker compose down --volumes",
22-
"lint": "oxlint .",
23-
"fix": "oxlint . --fix"
22+
"lint": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --type-aware",
23+
"lint:fix": "OXLINT_TSGOLINT_DANGEROUSLY_SUPPRESS_PROGRAM_DIAGNOSTICS=true oxlint . --fix --type-aware"
2424
},
2525
"dependencies": {
2626
"@sentry/node": "10.43.0",

0 commit comments

Comments
 (0)