()
| 384 | ]; |
| 385 | |
| 386 | function eslintCheck() { |
| 387 | // Use a single TS program (tsconfig.lint.json) for the whole repository, so |
| 388 | // that we don't need to split the work to stay under the heap size limit. |
| 389 | // Each worker has its own program: use a fixed number of workers, because |
| 390 | // the memory usage grows with it. |
| 391 | env( |
| 392 | () => |
| 393 | yarn([ |
| 394 | "eslint", |
| 395 | "packages", |
| 396 | ...ESLINT_NON_PACKAGES_SOURCES, |
| 397 | ...ESLINT_ARGS, |
| 398 | "--concurrency", |
| 399 | "2", |
| 400 | ]), |
| 401 | { |
| 402 | BABEL_ENV: "test", |
| 403 | BABEL_ESLINT_FLAT_TSCONFIG: "true", |
| 404 | // tsconfig.lint.json reports false positives when it's not a single run |
| 405 | TSESTREE_SINGLE_RUN: "true", |
| 406 | NODE_OPTIONS: "--max-old-space-size=6144", |
| 407 | } |
| 408 | ); |
| 409 | } |
| 410 | |
| 411 | function eslintFix() { |
| 412 | const eslintArgs = [...ESLINT_ARGS, "--concurrency", "auto", "--fix"]; |
no test coverage detected