Commit 2ff0e51
feat: Implement alternate config lookup (#18742)
* feat: Look up config file from file being linted
fixes #18385
* Fix ESLint class flag lookup
* Fix up tests for config lookup
* Add documentation for new config lookup flag
* Clean up directory searching behavior
* Read config files from starting from parent
* Cover edge cases
* Fix failing test
* Fix test and linting errors
* Remove .only from tests
* Fix failing test
* Incorporate TypeScript config files
* Fix lint errors
* Fix docs link
* Fix broken link
* Fix conflicts
* Update lib/config/config-loader.js
Co-authored-by: 唯然 <weiran.zsd@outlook.com>
* Update lib/config/config-loader.js
Co-authored-by: 唯然 <weiran.zsd@outlook.com>
* Update docs/src/use/configure/configuration-files.md
Co-authored-by: Francesco Trotta <github@fasttime.org>
* Add comment about CLI overrideConfig
* Remove duplicate code
* Fix error
* add test with a deep subdir
* Remove immediate child check
* Fix edge cases
* Clean up logic
* Ensure foo*/*.js doesn't traverse directory foo when ignored
* Ensure order of glob patterns doesn't matter
* Fix edge cases
* Don't normalize absolute path to posix
* add tests with overrideConfig and no config file
* Fix config override behavior
* Fix lint issues
* Update docs/src/use/configure/configuration-files.md
Co-authored-by: Milos Djermanovic <milos.djermanovic@gmail.com>
* Update docs/src/use/configure/configuration-files.md
Co-authored-by: Milos Djermanovic <milos.djermanovic@gmail.com>
* Update lib/config/config-loader.js
Co-authored-by: Milos Djermanovic <milos.djermanovic@gmail.com>
* Update lib/config/config-loader.js
Co-authored-by: Milos Djermanovic <milos.djermanovic@gmail.com>
* Update lib/config/config-loader.js
Co-authored-by: Milos Djermanovic <milos.djermanovic@gmail.com>
* Update lib/config/config-loader.js
Co-authored-by: Milos Djermanovic <milos.djermanovic@gmail.com>
* Update directory search to group by glob parent
* Simplify lookup
* Remove unused package
---------
Co-authored-by: 唯然 <weiran.zsd@outlook.com>
Co-authored-by: Francesco Trotta <github@fasttime.org>
Co-authored-by: Milos Djermanovic <milos.djermanovic@gmail.com>1 parent 2d17453 commit 2ff0e51
25 files changed
Lines changed: 8825 additions & 7453 deletions
File tree
- docs/src/use/configure
- lib
- config
- eslint
- tests
- fixtures
- config-lookup-ignores-2
- subdir1
- subdir2
- subdir3
- config-lookup-ignores
- subdir1
- subdir2
- subdir3/subsubdir
- lookup-from-file
- subdir
- no-config-file
- subdir-only-config/subdir
- lib
- eslint
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
499 | 499 | | |
500 | 500 | | |
501 | 501 | | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
502 | 518 | | |
503 | 519 | | |
504 | 520 | | |
| |||
511 | 527 | | |
512 | 528 | | |
513 | 529 | | |
| 530 | + | |
| 531 | + | |
514 | 532 | | |
515 | 533 | | |
516 | 534 | | |
| |||
560 | 578 | | |
561 | 579 | | |
562 | 580 | | |
563 | | - | |
| 581 | + | |
564 | 582 | | |
565 | 583 | | |
566 | 584 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
348 | 348 | | |
349 | 349 | | |
350 | 350 | | |
351 | | - | |
352 | | - | |
| 351 | + | |
353 | 352 | | |
354 | 353 | | |
355 | | - | |
356 | | - | |
357 | | - | |
358 | | - | |
359 | 354 | | |
360 | 355 | | |
361 | 356 | | |
| |||
0 commit comments