eslint-interactive 12.0.0 → 13.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (133) hide show
  1. package/README.md +34 -58
  2. package/bin/eslint-interactive.js +8 -11
  3. package/dist/action/index.d.ts +0 -2
  4. package/dist/action/index.d.ts.map +1 -1
  5. package/dist/action/index.js +0 -2
  6. package/dist/action/index.js.map +1 -1
  7. package/dist/action/print-result-details.d.ts.map +1 -1
  8. package/dist/action/print-result-details.js +6 -1
  9. package/dist/action/print-result-details.js.map +1 -1
  10. package/dist/cli/log.d.ts +3 -3
  11. package/dist/cli/log.d.ts.map +1 -1
  12. package/dist/cli/log.js +5 -4
  13. package/dist/cli/log.js.map +1 -1
  14. package/dist/cli/parse-argv.d.ts +2 -22
  15. package/dist/cli/parse-argv.d.ts.map +1 -1
  16. package/dist/cli/parse-argv.js +37 -43
  17. package/dist/cli/parse-argv.js.map +1 -1
  18. package/dist/cli/prompt.d.ts +1 -11
  19. package/dist/cli/prompt.d.ts.map +1 -1
  20. package/dist/cli/prompt.js +3 -44
  21. package/dist/cli/prompt.js.map +1 -1
  22. package/dist/cli/run.d.ts.map +1 -1
  23. package/dist/cli/run.js +6 -20
  24. package/dist/cli/run.js.map +1 -1
  25. package/dist/core-worker.d.ts +2 -4
  26. package/dist/core-worker.d.ts.map +1 -1
  27. package/dist/core-worker.js +3 -10
  28. package/dist/core-worker.js.map +1 -1
  29. package/dist/core.d.ts +8 -5
  30. package/dist/core.d.ts.map +1 -1
  31. package/dist/core.js +61 -47
  32. package/dist/core.js.map +1 -1
  33. package/dist/eslint/linter.d.ts +2 -3
  34. package/dist/eslint/linter.d.ts.map +1 -1
  35. package/dist/eslint/linter.js.map +1 -1
  36. package/dist/eslint/source-code-fixer.d.ts +1 -5
  37. package/dist/eslint/source-code-fixer.d.ts.map +1 -1
  38. package/dist/fix/make-fixable-and-fix.d.ts +2 -3
  39. package/dist/fix/make-fixable-and-fix.d.ts.map +1 -1
  40. package/dist/fix/make-fixable-and-fix.js +14 -41
  41. package/dist/fix/make-fixable-and-fix.js.map +1 -1
  42. package/dist/formatter/format-by-files.d.ts.map +1 -1
  43. package/dist/formatter/format-by-files.js +1 -0
  44. package/dist/formatter/format-by-files.js.map +1 -1
  45. package/dist/formatter/format-by-rules.d.ts +6 -1
  46. package/dist/formatter/format-by-rules.d.ts.map +1 -1
  47. package/dist/formatter/format-by-rules.js +7 -2
  48. package/dist/formatter/format-by-rules.js.map +1 -1
  49. package/dist/formatter/index.d.ts +3 -1
  50. package/dist/formatter/index.d.ts.map +1 -1
  51. package/dist/formatter/index.js +3 -2
  52. package/dist/formatter/index.js.map +1 -1
  53. package/dist/formatter/sort-rule-statistics.d.ts +5 -0
  54. package/dist/formatter/sort-rule-statistics.d.ts.map +1 -0
  55. package/dist/formatter/sort-rule-statistics.js +34 -0
  56. package/dist/formatter/sort-rule-statistics.js.map +1 -0
  57. package/dist/index.d.ts +2 -2
  58. package/dist/index.d.ts.map +1 -1
  59. package/dist/index.js +2 -2
  60. package/dist/index.js.map +1 -1
  61. package/dist/plugin.d.ts.map +1 -1
  62. package/dist/plugin.js +14 -0
  63. package/dist/plugin.js.map +1 -1
  64. package/dist/scene/lint.d.ts.map +1 -1
  65. package/dist/scene/lint.js +13 -14
  66. package/dist/scene/lint.js.map +1 -1
  67. package/dist/scene/select-action.d.ts.map +1 -1
  68. package/dist/scene/select-action.js +3 -9
  69. package/dist/scene/select-action.js.map +1 -1
  70. package/dist/type.d.ts +12 -0
  71. package/dist/type.d.ts.map +1 -0
  72. package/dist/type.js +2 -0
  73. package/dist/type.js.map +1 -0
  74. package/dist/util/eslint.d.ts.map +1 -1
  75. package/dist/util/eslint.js +1 -1
  76. package/dist/util/eslint.js.map +1 -1
  77. package/dist/util/type-check.d.ts +0 -3
  78. package/dist/util/type-check.d.ts.map +1 -1
  79. package/package.json +20 -20
  80. package/src/action/index.ts +0 -2
  81. package/src/action/print-result-details.ts +7 -1
  82. package/src/cli/log.ts +5 -4
  83. package/src/cli/parse-argv.ts +45 -61
  84. package/src/cli/prompt.ts +4 -48
  85. package/src/cli/run.ts +6 -22
  86. package/src/core-worker.ts +6 -21
  87. package/src/core.ts +52 -50
  88. package/src/eslint/linter.ts +2 -3
  89. package/src/fix/make-fixable-and-fix.ts +15 -47
  90. package/src/formatter/format-by-files.ts +1 -0
  91. package/src/formatter/format-by-rules.ts +18 -3
  92. package/src/formatter/index.ts +8 -3
  93. package/src/formatter/sort-rule-statistics.ts +35 -0
  94. package/src/index.ts +2 -2
  95. package/src/plugin.ts +14 -0
  96. package/src/scene/lint.ts +16 -18
  97. package/src/scene/select-action.ts +1 -8
  98. package/src/type.ts +13 -0
  99. package/src/util/eslint.ts +2 -2
  100. package/src/util/type-check.ts +0 -4
  101. package/bin/_eslint-interactive.js +0 -9
  102. package/dist/action/apply-suggestions.d.ts +0 -6
  103. package/dist/action/apply-suggestions.d.ts.map +0 -1
  104. package/dist/action/apply-suggestions.js +0 -27
  105. package/dist/action/apply-suggestions.js.map +0 -1
  106. package/dist/action/make-fixable-and-fix.d.ts +0 -6
  107. package/dist/action/make-fixable-and-fix.d.ts.map +0 -1
  108. package/dist/action/make-fixable-and-fix.js +0 -27
  109. package/dist/action/make-fixable-and-fix.js.map +0 -1
  110. package/dist/config.d.ts +0 -47
  111. package/dist/config.d.ts.map +0 -1
  112. package/dist/config.js +0 -98
  113. package/dist/config.js.map +0 -1
  114. package/dist/eslint/use-at-your-own-risk.d.ts +0 -5
  115. package/dist/eslint/use-at-your-own-risk.d.ts.map +0 -1
  116. package/dist/eslint/use-at-your-own-risk.js +0 -6
  117. package/dist/eslint/use-at-your-own-risk.js.map +0 -1
  118. package/dist/util/file-system.d.ts +0 -5
  119. package/dist/util/file-system.d.ts.map +0 -1
  120. package/dist/util/file-system.js +0 -10
  121. package/dist/util/file-system.js.map +0 -1
  122. package/dist/util/filter-script.d.ts +0 -6
  123. package/dist/util/filter-script.d.ts.map +0 -1
  124. package/dist/util/filter-script.js +0 -38
  125. package/dist/util/filter-script.js.map +0 -1
  126. package/src/action/apply-suggestions.ts +0 -39
  127. package/src/action/make-fixable-and-fix.ts +0 -39
  128. package/src/config.ts +0 -142
  129. package/src/eslint/use-at-your-own-risk.js +0 -6
  130. package/src/util/file-system.ts +0 -10
  131. package/src/util/filter-script.ts +0 -45
  132. package/static/example-filter-script.js +0 -40
  133. package/static/example-fixable-maker-script.js +0 -38
package/README.md CHANGED
@@ -15,7 +15,7 @@
15
15
 
16
16
  ## Motivation
17
17
 
18
- The default ESLint output contains a lot of useful messages for developers, such as the source of the error and hints for fixing it. While this works for many use cases, it does not work well in situations where many messages are reported. For example, when introducing ESLint into a project, or when making big changes to the `.eslintrc` of a project. In these situations, the output of ESLint can be quite large, making it difficult for developers to analyze the output. It is also difficult for the developer to fix messages mechanically, because messages of many rules are mixed up in the output.
18
+ The default ESLint output contains a lot of useful messages for developers, such as the source of the error and hints for fixing it. While this works for many use cases, it does not work well in situations where many messages are reported. For example, when introducing ESLint into a project, or when making big changes to the `eslint.config.js` of a project. In these situations, the output of ESLint can be quite large, making it difficult for developers to analyze the output. It is also difficult for the developer to fix messages mechanically, because messages of many rules are mixed up in the output.
19
19
 
20
20
  In such the above situation, I think two things are important:
21
21
 
@@ -32,21 +32,30 @@ It also supports the following actions in addition to `eslint --fix`. All action
32
32
 
33
33
  - Display details of lint results
34
34
  - Run `eslint --fix`
35
- - Disable per line (by `// eslint-disable-next-line <rule-name>`)
35
+ - Disable per line (`// eslint-disable-next-line <rule-name>`)
36
36
  - Disable per file (`/* eslint-disable <rule-name> */`)
37
+ - Add disable comments (`// eslint-disable <rule-name>`) per file.
37
38
  - Convert error to warning per file (`/* eslint <rule-name>: 1 */`)
38
- - Apply suggestions
39
- - Make forcibly fixable and run `eslint --fix`
39
+ - Apply suggestions (via [Programmable API](./docs/programmable-api.md) only)
40
+ - Select one of the applicable suggestions and apply it. ([What's _suggestions_?](#whats-suggestions))
41
+ - Users can write JavaScript code to programmatically select the suggestion to be applied.
42
+ - See [Programmable API documentation](./docs/programmable-api.md#applySuggestions) for details.
43
+ - Make forcibly fixable and run `eslint --fix` (via [Programmable API](./docs/programmable-api.md) only)
44
+ - This feature makes forcibly un-fixable problems fixable, and applies them.
45
+ - See [Programmable API documentation](./docs/programmable-api.md#makeFixableAndFix) for details.
40
46
 
41
47
  ## Requirements
42
48
 
43
- - Node.js `^20.19.0 || >=22.12.0`
44
- - ESLint `>=8.45.0`
49
+ - Node.js `^20.19.0 || ^22.12.0 || >=24.0.0`
50
+ - ESLint `>=9.0.0`
45
51
  - If you use ESLint `<8.45.0`, use `eslint-interactive@^10`.
52
+ - Flat config (`eslint.config.js`)
53
+ - If you use legacy config (`.eslintrc.*`), use `eslint-interactive@^12`.
46
54
 
47
55
  ## Installation
48
56
 
49
- :memo: NOTE: The globally installed `eslint-interactive` is **not officially supported**. It is recommended to install `eslint-interactive` locally. See [FAQ](#why-is-global-installation-not-officially-supported).
57
+ > [!WARNING]
58
+ > Global installation of `eslint-interactive` is **not recommended** and is only supported on a **best-effort basis**. It is recommended to install `eslint-interactive` locally. See [FAQ](#why-is-global-installation-not-recommended).
50
59
 
51
60
  ```console
52
61
  $ # For npm
@@ -64,62 +73,29 @@ $ pnpm exec eslint-interactive --help
64
73
 
65
74
  ## Usage
66
75
 
67
- The interface of `eslint-interactive` is partially compatible with `eslint`. So, in most cases, simply replacing `eslint` with `eslint-interactive` in the command to lint (e.g. `eslint ./src --ext .ts,.tsx`) will work. However, eslint-interactive is installed locally, so you need to add `npx`.
76
+ The interface of `eslint-interactive` is partially compatible with `eslint`. So, in most cases, simply replacing `eslint` with `eslint-interactive` in the command to lint (e.g. `eslint --quiet ./src`) will work. However, eslint-interactive is installed locally, so you need to add `npx`.
68
77
 
69
78
  ```console
70
79
  $ # Show help
71
80
  $ npx eslint-interactive --help
72
- eslint-interactive [file.js] [dir]
81
+ eslint-interactive [...patterns]
73
82
 
74
83
  Options:
75
- --help Show help [boolean]
76
- --version Show version number [boolean]
77
- --eslintrc Enable use of configuration from .eslintrc.* [boolean] [default: true]
78
- -c, --config Use this configuration, overriding .eslintrc.* config options if present [string]
79
- --resolve-plugins-relative-to A folder where plugins should be resolved from, CWD by default [string]
80
- --ext Specify JavaScript file extensions [array]
81
- --rulesdir Use additional rules from this directory [array]
82
- --ignore-path Specify path of ignore file [string]
83
- --format Specify the format to be used for the `Display problem messages` action [string] [default: "stylish"]
84
- --quiet Report errors only [boolean] [default: false]
85
- --cache Only check changed files [boolean] [default: false]
86
- --cache-location Path to the cache file or directory [string]
87
- --flag Enable a feature flag (requires ESLint v9.6.0+) [array]
88
-
84
+ --help Show help
85
+ --version Show version number
86
+ -c, --config <path> Use this configuration, overriding config options if present
87
+ --format <nameOrPath> Specify the format to be used for the "Display problem messages" action
88
+ --quiet Report errors only
89
+ --cache Only check changed files
90
+ --cache-location <path> Path to the cache file or directory
91
+ --flag <name> Enable a feature flag (requires ESLint v9.6.0+)
89
92
 
90
93
  Examples:
91
- eslint-interactive ./src Lint ./src/ directory
92
- eslint-interactive ./src ./test Lint multiple directories
93
- eslint-interactive './src/**/*.{ts,tsx,vue}' Lint with glob pattern
94
- eslint-interactive ./src --ext .ts,.tsx,.vue Lint with custom extensions
95
- eslint-interactive ./src --rulesdir ./rules Lint with custom rules
96
- eslint-interactive ./src --no-eslintrc --config ./.eslintrc.ci.js Lint with custom config
94
+ eslint-interactive Lint all files in the project
95
+ eslint-interactive src test Lint specified directories
96
+ eslint-interactive 'src/**/*.{ts,tsx,vue}' Lint with glob pattern
97
97
  ```
98
98
 
99
- ## Available actions
100
-
101
- Actions can be executed per rule.
102
-
103
- - Display details of lint results
104
- - Displays ESLint error reports.
105
- - Run `eslint --fix`
106
- - Apply fixable problems.
107
- - Disable per line
108
- - Add disable comments (`// eslint-disable-next-line <rule-name>`) per line.
109
- - Disable per file
110
- - Add disable comments (`// eslint-disable <rule-name>`) per file.
111
- - Convert error to warning per file
112
- - Add inline config comments (`/* eslint <rule-name>: 1 */`) per file.
113
- - Apply suggestions (experimental, for experts)
114
- - Select one of the applicable suggestions and apply it. ([What's _suggestions_?](#whats-suggestions))
115
- - Users can write JavaScript code to programmatically select the suggestion to be applied.
116
- - The tool will tell you how to use the feature in detail. Please follow the instructions of the tool.
117
- - This feature is experimental and may change significantly.
118
- - Make forcibly fixable and run `eslint --fix` (experimental, for experts)
119
- - This feature make forcibly un-fixable problems fixable, and apply them.
120
- - The tool will tell you how to use the feature in detail. Please follow the instructions of the tool.
121
- - This feature is experimental and may change significantly.
122
-
123
99
  ## Programmable API
124
100
 
125
101
  See [Programmable API documentation](./docs/programmable-api.md).
@@ -138,13 +114,13 @@ In some cases fixes aren't appropriate to be automatically applied, for example,
138
114
 
139
115
  Suggestion can be one or more. The user has to manually decide if that fix should be applied or which fix should be applied because automatically applying of suggestion is inappropriate. For this reason, ESLint has stated that it will not officially provide a way to automatically apply suggestion ([ref](https://github.com/eslint/rfcs/tree/64b2511da6f2c10e1692671315459eb916aea53f/designs/2019-suggestions#:~:text=Unlike%20fixes%2C%20suggestion%20will%20not%20expose%20a%20new%20API%20function)). Instead, tools such as [`vscode-eslint`](https://github.com/microsoft/vscode-eslint) allow users to apply suggestions manually ([ref](https://github.com/microsoft/vscode-eslint/pull/814#issuecomment-587011529)).
140
116
 
141
- ### Why is global installation not officially supported?
117
+ ### Why is global installation not recommended?
142
118
 
143
- `eslint` is installed locally in most projects. In such a case, if `eslint-interactive` is installed globally, it will be installed in a different space than `eslint`. The space separation makes some resources of `eslint-interactive` inaccessible from `eslint` and may break them (ref: [#77](https://github.com/mizdra/eslint-interactive/issues/77)). Therefore, global installation of `eslint-interactive` is not officially supported.
119
+ `eslint` is installed locally in most projects. In such a case, if `eslint-interactive` is installed globally, it will be installed in a different space than `eslint`. The space separation makes some resources of `eslint-interactive` inaccessible from `eslint` and may break them (ref: [#77](https://github.com/mizdra/eslint-interactive/issues/77)). For this reason, local installation is recommended. Global installation is supported, but only on a best-effort basis.
144
120
 
145
121
  ### Is global installation prohibited?
146
122
 
147
- No. `eslint-interactive` does not prohibit global installation. Global installation is allowed because it has the advantage of saving installation effort. However, it is not officially supported and users must use it at their own risk.
123
+ No. `eslint-interactive` does not prohibit global installation. Global installation is supported on a best-effort basis because it has the advantage of saving installation effort. However, it is not recommended and users should be aware that some issues may arise.
148
124
 
149
125
  If the global installation does not work, you can send a patch by pull request. However, whether the patch will be accepted depends on the case.
150
126
 
@@ -160,6 +136,6 @@ Thanks, [@IanVS](https://github.com/IanVS).
160
136
 
161
137
  [suppress-eslint-errors](https://github.com/amanda-mitchell/suppress-eslint-errors) is an excellent tool to add comments for disable mechanically. Just like `eslint-interactive`, it allows you to add disable comments for each rule and leave the purpose of disable as a comment. There is no functional difference between the two, but there is a difference in the API used to insert the comments.
162
138
 
163
- `suppress-eslint-errors` uses [`jscodeshift`](https://github.com/facebook/jscodeshift) to insert comments. `jscodeshift` modifies the file in parallel, so `suppress-eslint-errors` has the advantage of being able to insert comments faster. However, `jscodeshift` cannot reuse the AST of ESLint, so you need to reparse the code in `jscodeshift`. This means that you have to pass `jscodeshift` the information it needs to parse your code (parser type, parser options). In fact, `suppress-eslint-errors` requires `--extensions` and `--parser` command line option. Normally, users specify the parsing options in `.eslintrc`, so passing these options may seem cumbersome. Also, due to the difference in the way ESLint and `jscodeshift` parse, it may not be possible to insert comments correctly.
139
+ `suppress-eslint-errors` uses [`jscodeshift`](https://github.com/facebook/jscodeshift) to insert comments. `jscodeshift` modifies the file in parallel, so `suppress-eslint-errors` has the advantage of being able to insert comments faster. However, `jscodeshift` cannot reuse the AST of ESLint, so you need to reparse the code in `jscodeshift`. This means that you have to pass `jscodeshift` the information it needs to parse your code (parser type, parser options). In fact, `suppress-eslint-errors` requires `--extensions` and `--parser` command line option. Normally, users specify the parsing options in `eslint.config.js`, so passing these options may seem cumbersome. Also, due to the difference in the way ESLint and `jscodeshift` parse, it may not be possible to insert comments correctly.
164
140
 
165
- On the other hand, `eslint-interactive` uses [`ESLint.outputFixes`](https://eslint.org/docs/developer-guide/nodejs-api#-eslintoutputfixesresults) to insert comments. It uses ESLint's API to do everything from parsing the code to inserting the comments, so it works as expected in many cases. Also, `eslint-interactive` will parse the code using the parsing options specified in `.eslintrc`. Therefore, comments can be inserted without any additional command line options. By the way, comment insertion is slower than `suppress-eslint-errors` because, unlike `suppress-eslint-errors`, it cannot modify files in parallel. However, this limitation may be improved when ESLint supports parallel processing in the near future.
141
+ On the other hand, `eslint-interactive` uses [`ESLint.outputFixes`](https://eslint.org/docs/developer-guide/nodejs-api#-eslintoutputfixesresults) to insert comments. It uses ESLint's API to do everything from parsing the code to inserting the comments, so it works as expected in many cases. Also, `eslint-interactive` will parse the code using the parsing options specified in `eslint.config.js`. Therefore, comments can be inserted without any additional command line options. By the way, comment insertion is slower than `suppress-eslint-errors` because, unlike `suppress-eslint-errors`, it cannot modify files in parallel. However, this limitation may be improved when ESLint supports parallel processing in the near future.
@@ -1,13 +1,10 @@
1
1
  #!/usr/bin/env node
2
2
  // @ts-check
3
-
4
- import { spawnSync } from 'child_process';
5
- import { resolve } from 'path';
6
- import { dirname, join } from 'path';
7
- import { fileURLToPath } from 'url';
8
-
9
- const dir = join(dirname(fileURLToPath(import.meta.url)));
10
-
11
- const scriptFile = resolve(dir, '_eslint-interactive.js');
12
-
13
- spawnSync('node', ['--unhandled-rejections=strict', scriptFile, ...process.argv.slice(2)], { stdio: 'inherit' });
3
+ import { run } from '../dist/index.js';
4
+
5
+ run({
6
+ argv: process.argv,
7
+ }).catch((error) => {
8
+ console.error(error);
9
+ process.exit(1);
10
+ });
@@ -1,8 +1,6 @@
1
- export { doApplySuggestionsAction } from './apply-suggestions.js';
2
1
  export { doDisablePerFileAction } from './disable-per-file.js';
3
2
  export { doDisablePerLineAction } from './disable-per-line.js';
4
3
  export { doConvertErrorToWarningPerFileAction } from './convert-error-to-warning-per-file.js';
5
4
  export { doFixAction } from './fix.js';
6
- export { doMakeFixableAndFixAction } from './make-fixable-and-fix.js';
7
5
  export { doPrintResultDetailsAction } from './print-result-details.js';
8
6
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/action/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,MAAM,wBAAwB,CAAC;AAClE,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EAAE,oCAAoC,EAAE,MAAM,wCAAwC,CAAC;AAC9F,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,EAAE,yBAAyB,EAAE,MAAM,2BAA2B,CAAC;AACtE,OAAO,EAAE,0BAA0B,EAAE,MAAM,2BAA2B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/action/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EAAE,oCAAoC,EAAE,MAAM,wCAAwC,CAAC;AAC9F,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,EAAE,0BAA0B,EAAE,MAAM,2BAA2B,CAAC"}
@@ -1,8 +1,6 @@
1
- export { doApplySuggestionsAction } from './apply-suggestions.js';
2
1
  export { doDisablePerFileAction } from './disable-per-file.js';
3
2
  export { doDisablePerLineAction } from './disable-per-line.js';
4
3
  export { doConvertErrorToWarningPerFileAction } from './convert-error-to-warning-per-file.js';
5
4
  export { doFixAction } from './fix.js';
6
- export { doMakeFixableAndFixAction } from './make-fixable-and-fix.js';
7
5
  export { doPrintResultDetailsAction } from './print-result-details.js';
8
6
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/action/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,MAAM,wBAAwB,CAAC;AAClE,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EAAE,oCAAoC,EAAE,MAAM,wCAAwC,CAAC;AAC9F,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,EAAE,yBAAyB,EAAE,MAAM,2BAA2B,CAAC;AACtE,OAAO,EAAE,0BAA0B,EAAE,MAAM,2BAA2B,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/action/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EAAE,oCAAoC,EAAE,MAAM,wCAAwC,CAAC;AAC9F,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,EAAE,0BAA0B,EAAE,MAAM,2BAA2B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"print-result-details.d.ts","sourceRoot":"","sources":["../../src/action/print-result-details.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AACtC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAGrC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAI1D,wBAAsB,0BAA0B,CAC9C,IAAI,EAAE,MAAM,CAAC,gBAAgB,CAAC,EAC9B,OAAO,EAAE,MAAM,CAAC,UAAU,EAAE,EAC5B,eAAe,EAAE,MAAM,EAAE,iBAkB1B"}
1
+ {"version":3,"file":"print-result-details.d.ts","sourceRoot":"","sources":["../../src/action/print-result-details.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AACtC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAIrC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAG1D,wBAAsB,0BAA0B,CAC9C,IAAI,EAAE,MAAM,CAAC,gBAAgB,CAAC,EAC9B,OAAO,EAAE,MAAM,CAAC,UAAU,EAAE,EAC5B,eAAe,EAAE,MAAM,EAAE,iBAkB1B"}
@@ -1,10 +1,12 @@
1
1
  import { writeFile } from 'node:fs/promises';
2
2
  import { mkdir } from 'node:fs/promises';
3
+ import { tmpdir } from 'node:os';
3
4
  import { join } from 'node:path';
5
+ // eslint-disable-next-line n/no-unsupported-features/node-builtins
4
6
  import { stripVTControlCharacters, styleText } from 'node:util';
7
+ import { VERSION } from '../cli/package.js';
5
8
  import { pager } from '../cli/pager.js';
6
9
  import { promptToInputDisplayMode } from '../cli/prompt.js';
7
- import { getTempDir } from '../util/file-system.js';
8
10
  import { unreachable } from '../util/type-check.js';
9
11
  export async function doPrintResultDetailsAction(core, results, selectedRuleIds) {
10
12
  const displayMode = await promptToInputDisplayMode();
@@ -27,4 +29,7 @@ export async function doPrintResultDetailsAction(core, results, selectedRuleIds)
27
29
  unreachable(`Unknown display mode: ${displayMode}`);
28
30
  }
29
31
  }
32
+ function getTempDir() {
33
+ return join(tmpdir(), 'eslint-interactive', VERSION);
34
+ }
30
35
  //# sourceMappingURL=print-result-details.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"print-result-details.js","sourceRoot":"","sources":["../../src/action/print-result-details.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AACzC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,wBAAwB,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAGhE,O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AAC,sBAAsB,CAAC,EAAE,MAAM,CAAC,CAAC;QACpF,OAAO,CAAC,GAAG,CAAC,SAAS,CAAC,MAAM,EAAE,YAAY,QAAQ,EAAE,CAAC,CAAC,CAAC;IACzD,CAAC;SAAM,CAAC;QACN,4EAA4E;QAC5E,WAAW,CAAC,yBAAyB,WAAW,EAAE,CAAC,CAAC;IACtD,CAAC;AACH,CAAC;AAED,SAAS,UAAU;IACjB,OAAO,IAAI,CAAC,MAAM,EAAE,EAAE,oBAAoB,EAAE,OAAO,CAAC,CAAC;AACvD,CAAC"}
package/dist/cli/log.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  /**
2
- * Log a warning message to stderr
3
- * @param message The message to warn
2
+ * Log an error message to stderr
3
+ * @param message The message to report
4
4
  */
5
- export declare function warn(message: string): void;
5
+ export declare function error(message: string): void;
6
6
  //# sourceMappingURL=log.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"log.d.ts","sourceRoot":"","sources":["../../src/cli/log.ts"],"names":[],"mappings":"AAEA;;;GAGG;AACH,wBAAgB,IAAI,CAAC,OAAO,EAAE,MAAM,QAEnC"}
1
+ {"version":3,"file":"log.d.ts","sourceRoot":"","sources":["../../src/cli/log.ts"],"names":[],"mappings":"AAGA;;;GAGG;AACH,wBAAgB,KAAK,CAAC,OAAO,EAAE,MAAM,QAEpC"}
package/dist/cli/log.js CHANGED
@@ -1,9 +1,10 @@
1
+ // eslint-disable-next-line n/no-unsupported-features/node-builtins
1
2
  import { styleText } from 'node:util';
2
3
  /**
3
- * Log a warning message to stderr
4
- * @param message The message to warn
4
+ * Log an error message to stderr
5
+ * @param message The message to report
5
6
  */
6
- export function warn(message) {
7
- process.stderr.write(styleText('yellow', 'Warning') + ': ' + message + '\n');
7
+ export function error(message) {
8
+ process.stderr.write(styleText('red', 'Error') + ': ' + message + '\n');
8
9
  }
9
10
  //# sourceMappingURL=log.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"log.js","sourceRoot":"","sources":["../../src/cli/log.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAEtC;;;GAGG;AACH,MAAM,UAAU,IAAI,CAAC,OAAe;IAClC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,SAAS,CAAC,QAAQ,EAAE,SAAS,CAAC,GAAG,IAAI,GAAG,OAAO,GAAG,IAAI,CAAC,CAAC;AAC/E,CAAC"}
1
+ {"version":3,"file":"log.js","sourceRoot":"","sources":["../../src/cli/log.ts"],"names":[],"mappings":"AAAA,mEAAmE;AACnE,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAEtC;;;GAGG;AACH,MAAM,UAAU,KAAK,CAAC,OAAe;IACnC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,SAAS,CAAC,KAAK,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,OAAO,GAAG,IAAI,CAAC,CAAC;AAC1E,CAAC"}
@@ -1,24 +1,4 @@
1
- export type ParsedCLIOptions = {
2
- patterns: string[];
3
- formatterName: string | undefined;
4
- quiet: boolean | undefined;
5
- useEslintrc: boolean | undefined;
6
- overrideConfigFile: string | undefined;
7
- extensions: string[] | undefined;
8
- rulePaths: string[] | undefined;
9
- ignorePath: string | undefined;
10
- cache: boolean | undefined;
11
- cacheLocation: string | undefined;
12
- resolvePluginsRelativeTo: string | undefined;
13
- flags: string[] | undefined;
14
- };
15
- /** Default CLI Options */
16
- export declare const cliOptionsDefaults: {
17
- formatterName: string;
18
- quiet: false;
19
- useEslintrc: true;
20
- cache: false;
21
- };
1
+ import type { Config } from '../type.js';
22
2
  /** Parse CLI options */
23
- export declare function parseArgv(argv: string[]): ParsedCLIOptions;
3
+ export declare function parseArgv(argv: string[]): Config;
24
4
  //# sourceMappingURL=parse-argv.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"parse-argv.d.ts","sourceRoot":"","sources":["../../src/cli/parse-argv.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,aAAa,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,KAAK,EAAE,OAAO,GAAG,SAAS,CAAC;IAC3B,WAAW,EAAE,OAAO,GAAG,SAAS,CAAC;IACjC,kBAAkB,EAAE,MAAM,GAAG,SAAS,CAAC;IACvC,UAAU,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;IACjC,SAAS,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;IAChC,UAAU,EAAE,MAAM,GAAG,SAAS,CAAC;IAC/B,KAAK,EAAE,OAAO,GAAG,SAAS,CAAC;IAC3B,aAAa,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,wBAAwB,EAAE,MAAM,GAAG,SAAS,CAAC;IAC7C,KAAK,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;CAC7B,CAAC;AAEF,0BAA0B;AAC1B,eAAO,MAAM,kBAAkB;;;;;CAKU,CAAC;AAE1C,wBAAwB;AACxB,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,gBAAgB,CAiF1D"}
1
+ {"version":3,"file":"parse-argv.d.ts","sourceRoot":"","sources":["../../src/cli/parse-argv.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAwB,MAAM,YAAY,CAAC;AAM/D,wBAAwB;AACxB,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,MAAM,CAqFhD"}
@@ -1,28 +1,20 @@
1
1
  import { parseArgs } from 'node:util';
2
2
  import { VERSION } from './package.js';
3
- /** Default CLI Options */
4
- export const cliOptionsDefaults = {
5
- formatterName: 'stylish',
6
- quiet: false,
7
- useEslintrc: true,
8
- cache: false,
9
- };
3
+ const VALID_SORT_FIELDS = ['rule', 'error', 'warning', 'fixable', 'suggestions'];
4
+ const VALID_SORT_ORDERS = ['asc', 'desc'];
10
5
  /** Parse CLI options */
11
6
  export function parseArgv(argv) {
12
7
  const options = {
13
- 'eslintrc': { type: 'boolean', default: cliOptionsDefaults.useEslintrc },
14
8
  'config': { type: 'string', short: 'c' },
15
- 'ext': { type: 'string', multiple: true },
16
- 'resolve-plugins-relative-to': { type: 'string' },
17
- 'rulesdir': { type: 'string', multiple: true },
18
- 'ignore-path': { type: 'string' },
19
- 'format': { type: 'string', default: cliOptionsDefaults.formatterName },
20
- 'quiet': { type: 'boolean', default: cliOptionsDefaults.quiet },
21
- 'cache': { type: 'boolean', default: cliOptionsDefaults.cache },
9
+ 'format': { type: 'string' },
10
+ 'quiet': { type: 'boolean' },
11
+ 'cache': { type: 'boolean' },
22
12
  'cache-location': { type: 'string' },
23
13
  'version': { type: 'boolean' },
24
14
  'help': { type: 'boolean' },
25
15
  'flag': { type: 'string', multiple: true },
16
+ 'sort': { type: 'string' },
17
+ 'sort-order': { type: 'string' },
26
18
  };
27
19
  const { values, positionals } = parseArgs({
28
20
  allowPositionals: true,
@@ -31,6 +23,17 @@ export function parseArgv(argv) {
31
23
  args: argv.slice(2),
32
24
  options,
33
25
  });
26
+ // Validate `--sort` and `--sort-order`
27
+ if (values.sort !== undefined && !VALID_SORT_FIELDS.includes(values.sort)) {
28
+ console.error(`Invalid --sort value: "${values.sort}". Must be one of: ${VALID_SORT_FIELDS.join(', ')}`);
29
+ // eslint-disable-next-line n/no-process-exit
30
+ process.exit(1);
31
+ }
32
+ if (values['sort-order'] !== undefined && !VALID_SORT_ORDERS.includes(values['sort-order'])) {
33
+ console.error(`Invalid --sort-order value: "${values['sort-order']}". Must be one of: ${VALID_SORT_ORDERS.join(', ')}`);
34
+ // eslint-disable-next-line n/no-process-exit
35
+ process.exit(1);
36
+ }
34
37
  if (values.version) {
35
38
  console.log(VERSION);
36
39
  // eslint-disable-next-line n/no-process-exit
@@ -38,51 +41,42 @@ export function parseArgv(argv) {
38
41
  }
39
42
  if (values.help) {
40
43
  console.log(`
41
- eslint-interactive [file.js] [dir]
44
+ eslint-interactive [...patterns]
42
45
 
43
46
  Options:
44
- --help Show help [boolean]
45
- --version Show version number [boolean]
46
- --eslintrc Enable use of configuration from .eslintrc.* [boolean] [default: true]
47
- -c, --config Use this configuration, overriding .eslintrc.* config options if present [string]
48
- --resolve-plugins-relative-to A folder where plugins should be resolved from, CWD by default [string]
49
- --ext Specify JavaScript file extensions [array]
50
- --rulesdir Use additional rules from this directory [array]
51
- --ignore-path Specify path of ignore file [string]
52
- --format Specify the format to be used for the \`Display problem messages\` action [string] [default: "stylish"]
53
- --quiet Report errors only [boolean] [default: false]
54
- --cache Only check changed files [boolean] [default: false]
55
- --cache-location Path to the cache file or directory [string]
56
- --flag Enable a feature flag (requires ESLint v9.6.0+) [array]
47
+ --help Show help
48
+ --version Show version number
49
+ -c, --config <path> Use this configuration, overriding config options if present
50
+ --format <nameOrPath> Specify the format to be used for the "Display problem messages" action
51
+ --quiet Report errors only
52
+ --cache Only check changed files
53
+ --cache-location <path> Path to the cache file or directory
54
+ --flag <name> Enable a feature flag (requires ESLint v9.6.0+)
55
+ --sort <field> Sort rules by: rule, error, warning, fixable, suggestions
56
+ --sort-order <direction> Sort direction: asc, desc (default: desc for counts, asc for rule)
57
57
 
58
58
  Examples:
59
- eslint-interactive ./src Lint ./src/ directory
60
- eslint-interactive ./src ./test Lint multiple directories
61
- eslint-interactive './src/**/*.{ts,tsx,vue}' Lint with glob pattern
62
- eslint-interactive ./src --ext .ts,.tsx,.vue Lint with custom extensions
63
- eslint-interactive ./src --rulesdir ./rules Lint with custom rules
64
- eslint-interactive ./src --no-eslintrc --config ./.eslintrc.ci.js Lint with custom config
65
- `);
59
+ eslint-interactive Lint all files in the project
60
+ eslint-interactive src test Lint specified directories
61
+ eslint-interactive 'src/**/*.{ts,tsx,vue}' Lint with glob pattern
62
+ eslint-interactive --sort error Sort rules by error count (descending)
63
+ eslint-interactive --sort rule Sort rules by rule name (ascending)
64
+ `.trim());
66
65
  // eslint-disable-next-line n/no-process-exit
67
66
  process.exit(0);
68
67
  }
69
68
  const patterns = positionals.map((pattern) => pattern.toString());
70
- const rulePaths = values.rulesdir?.map((rulePath) => rulePath.toString());
71
- const extensions = values.ext?.map((extension) => extension.toString()).flatMap((extension) => extension.split(','));
72
69
  const formatterName = values.format;
73
70
  return {
74
71
  patterns,
75
72
  formatterName,
76
73
  quiet: values.quiet,
77
- useEslintrc: values.eslintrc,
78
74
  overrideConfigFile: values.config,
79
- extensions,
80
- rulePaths,
81
- ignorePath: values['ignore-path'],
82
75
  cache: values.cache,
83
76
  cacheLocation: values['cache-location'],
84
- resolvePluginsRelativeTo: values['resolve-plugins-relative-to'],
85
77
  flags: values.flag,
78
+ sort: values.sort,
79
+ sortOrder: values['sort-order'],
86
80
  };
87
81
  }
88
82
  //# sourceMappingURL=parse-argv.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"parse-argv.js","sourceRoot":"","sources":["../../src/cli/parse-argv.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAEtC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAiBvC,0BAA0B;AAC1B,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,aAAa,EAAE,SAAS;IACxB,KAAK,EAAE,KAAK;IACZ,WAAW,EAAE,IAAI;IACjB,KAAK,EAAE,KAAK;CAC2B,CAAC;AAE1C,wBAAwB;AACxB,MAAM,UAAU,SAAS,CAAC,IAAc;IACtC,MAAM,OAAO,GAAG;QACd,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,OAAO,EAAE,kBAAkB,CAAC,WAAW,EAAE;QACxE,QAAQ,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,GAAG,EAAE;QACxC,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;QACzC,6BAA6B,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QACjD,UAAU,EAAE,EAAE,IAAI,EAAE,QAAQ,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AAC,YAAY,CAAc,CAAC,EAAE,CAAC;QACzG,OAAO,CAAC,KAAK,CACX,gCAAgC,MAAM,CAAC,YAAY,CAAC,sBAAsB,iBAAiB,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CACzG,CAAC;QACF,6CAA6C;QAC7C,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;IAED,IAAI,MAAM,CAAC,OAAO,EAAE,CAAC;QACnB,OAAO,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;QACrB,6CAA6C;QAC7C,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;IAED,IAAI,MAAM,CAAC,IAAI,EAAE,CAAC;QAChB,OAAO,CAAC,GAAG,CACT;;;;;;;;;;;;;;;;;;;;;CAqBL,CAAC,IAAI,EAAE,CACH,CAAC;QACF,6CAA6C;QAC7C,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;IAED,MAAM,QAAQ,GAAG,WAAW,CAAC,GAAG,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC;IAClE,MAAM,aAAa,GAAG,MAAM,CAAC,MAAM,CAAC;IAEpC,OAAO;QACL,QAAQ;QACR,aAAa;QACb,KAAK,EAAE,MAAM,CAAC,KAAK;QACnB,kBAAkB,EAAE,MAAM,CAAC,MAAM;QACjC,KAAK,EAAE,MAAM,CAAC,KAAK;QACnB,aAAa,EAAE,MAAM,CAAC,gBAAgB,CAAC;QACvC,KAAK,EAAE,MAAM,CAAC,IAAI;QAClB,IAAI,EAAE,MAAM,CAAC,IAA6B;QAC1C,SAAS,EAAE,MAAM,CAAC,YAAY,CAA0B;KACzD,CAAC;AACJ,CAAC"}
@@ -2,7 +2,7 @@ import type { ESLint } from 'eslint';
2
2
  /**
3
3
  * The type that indicates what to do with the problems of selected rules.
4
4
  */
5
- export type Action = 'printResultDetails' | 'applyAutoFixes' | 'disablePerLine' | 'disablePerFile' | 'convertErrorToWarningPerFile' | 'applySuggestions' | 'makeFixableAndFix' | 'reselectRules';
5
+ export type Action = 'printResultDetails' | 'applyAutoFixes' | 'disablePerLine' | 'disablePerFile' | 'convertErrorToWarningPerFile' | 'relintAndReselectRules' | 'reselectRules';
6
6
  /**
7
7
  * The type representing how to display the lint results.
8
8
  *
@@ -47,15 +47,5 @@ export declare function promptToInputDescriptionPosition(): Promise<DescriptionP
47
47
  * @returns What to do next.
48
48
  */
49
49
  export declare function promptToInputWhatToDoNext(): Promise<NextStep>;
50
- /**
51
- * Ask the user if they want to reuse the filter script.
52
- * @returns If it reuses, `true`, if not, `false`.
53
- */
54
- export declare function promptToInputReuseFilterScript(): Promise<boolean>;
55
- /**
56
- * Ask the user if they want to reuse the script.
57
- * @returns If it reuses, `true`, if not, `false`.
58
- */
59
- export declare function promptToInputReuseScript(): Promise<boolean>;
60
50
  export {};
61
51
  //# sourceMappingURL=prompt.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"prompt.d.ts","sourceRoot":"","sources":["../../src/cli/prompt.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAUrC;;GAEG;AACH,MAAM,MAAM,MAAM,GACd,oBAAoB,GACpB,gBAAgB,GAChB,gBAAgB,GAChB,gBAAgB,GAChB,8BAA8B,GAC9B,kBAAkB,GAClB,mBAAmB,GACnB,eAAe,CAAC;AAEpB;;;;;;GAMG;AACH,KAAK,WAAW,GAAG,iBAAiB,GAAG,0BAA0B,GAAG,aAAa,CAAC;AAElF;;GAEG;AACH,KAAK,QAAQ,GAAG,eAAe,GAAG,MAAM,GAAG,YAAY,CAAC;AAExD,MAAM,MAAM,mBAAmB,GAAG,UAAU,GAAG,cAAc,CAAC;AAE9D;;;;GAIG;AACH,wBAAsB,oBAAoB,CAAC,gBAAgB,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,CAgBxF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AED;;;GAGG;AACH,wBAAsB,mBAAmB,CACvC,OAAO,EAAE,MAAM,CAAC,UAAU,EAAE,EAC5B,eAAe,EAAE,MAAM,EAAE,EACzB,aAAa,CAAC,EAAE,MAAM,GACrB,OAAO,CAAC,MAAM,CAAC,CAkCjB;AAED;;;GAGG;AACH,wBAAsB,wBAAwB,IAAI,OAAO,CAAC,WAAW,CAAC,CAiBrE;AAED;;;GAGG;AACH,wBAAsB,wBAAwB,IAAI,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAY5E;AAED;;;GAGG;AACH,wBAAsB,gCAAgC,IAAI,OAAO,CAAC,mBAAmB,CAAC,CAgBrF;AAED;;;GAGG;AACH,wBAAsB,yBAAyB,IAAI,OAAO,CAAC,QAAQ,CAAC,CAenE"}
@@ -36,24 +36,15 @@ export async function promptToInputAction(results, selectedRuleIds, initialActio
36
36
  const ruleStatistics = takeRuleStatistics(results).filter((ruleStatistic) => selectedRuleIds.includes(ruleStatistic.ruleId));
37
37
  const foldedStatistics = ruleStatistics.reduce((a, b) => ({
38
38
  isFixableCount: a.isFixableCount + b.isFixableCount,
39
- hasSuggestionsCount: a.hasSuggestionsCount + b.hasSuggestionsCount,
40
- }), { isFixableCount: 0, hasSuggestionsCount: 0 });
39
+ }), { isFixableCount: 0 });
41
40
  const choices = [
42
41
  { name: 'printResultDetails', message: '🔎 Display details of lint results' },
43
42
  { name: 'applyAutoFixes', message: '🔧 Run `eslint --fix`', disabled: foldedStatistics.isFixableCount === 0 },
44
43
  { name: 'disablePerLine', message: '🔧 Disable per line' },
45
44
  { name: 'disablePerFile', message: '🔧 Disable per file' },
46
45
  { name: 'convertErrorToWarningPerFile', message: '🔧 Convert error to warning per file' },
47
- {
48
- name: 'applySuggestions',
49
- message: '🔧 Apply suggestions (experimental, for experts)',
50
- disabled: foldedStatistics.hasSuggestionsCount === 0,
51
- },
52
- {
53
- name: 'makeFixableAndFix',
54
- message: '🔧 Make forcibly fixable and run `eslint --fix` (experimental, for experts)',
55
- },
56
- { name: 'reselectRules', message: 'â†Šī¸ Reselect rules' },
46
+ { name: 'relintAndReselectRules', message: 'â†Šī¸ Go back (with re-lint)' },
47
+ { name: 'reselectRules', message: 'â†Šī¸ Go back' },
57
48
  ];
58
49
  const { action } = await prompt([
59
50
  {
@@ -141,36 +132,4 @@ export async function promptToInputWhatToDoNext() {
141
132
  ]);
142
133
  return nextStep;
143
134
  }
144
- /**
145
- * Ask the user if they want to reuse the filter script.
146
- * @returns If it reuses, `true`, if not, `false`.
147
- */
148
- export async function promptToInputReuseFilterScript() {
149
- const { reuseFilterScript } = await prompt([
150
- {
151
- name: 'reuseFilterScript',
152
- type: 'confirm',
153
- message: 'Do you want to reuse a previously edited filter script?',
154
- initial: true,
155
- onCancel,
156
- },
157
- ]);
158
- return reuseFilterScript;
159
- }
160
- /**
161
- * Ask the user if they want to reuse the script.
162
- * @returns If it reuses, `true`, if not, `false`.
163
- */
164
- export async function promptToInputReuseScript() {
165
- const { reuseScript } = await prompt([
166
- {
167
- name: 'reuseScript',
168
- type: 'confirm',
169
- message: 'Do you want to reuse a previously edited script?',
170
- initial: true,
171
- onCancel,
172
- },
173
- ]);
174
- return reuseScript;
175
- }
176
135
  //# sourceMappingURL=prompt.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"prompt.js","sourceRoot":"","sources":["../../src/cli/prompt.ts"],"names":[],"mappings":"AAAA,0BAA0B;AAE1B,OAAO,QAAQ,MAAM,UAAU,CAAC;AAEhC,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAE3D,MAAM,EAAE,MAAM,EAAE,GAAG,QAAQ,CAAC;AAE5B,iHAAiH;AACjH,mDAAmD;AACnD,6CAA6C;AAC7C,MAAM,QAAQ,GAAG,GAAG,EAAE,CAAC,OAAO,CAAC,IAAI,EAAE,CAAC;AA+BtC;;;;GAIG;AACH,MAAM,CAAC,KAAK,UAAU,oBAAoB,CAAC,gBAA0B;IACnE,MAAM,EAAE,OAAO,EAAE,G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O,EAAE,qEAAqE,EAAE;gBACpG,EAAE,IAAI,EAAE,cAAc,EAAE,OAAO,EAAE,wEAAwE,EAAE;aAC5G;YACD,QAAQ;SACT;KACF,CAAC,CAAC;IACH,OAAO,mBAAmB,CAAC;AAC7B,CAAC;AAED;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,yBAAyB;IAC7C,MAAM,EAAE,QAAQ,EAAE,GAAG,MAAM,MAAM,CAAyB;QACxD;YACE,IAAI,EAAE,UAAU;YAChB,IAAI,EAAE,QAAQ;YACd,OAAO,EAAE,uBAAuB;YAChC,OAAO,EAAE;gBACP,EAAE,IAAI,EAAE,eAAe,EAAE,OAAO,EAAE,oBAAoB,EAAE;gBACxD,EAAE,IAAI,EAAE,YAAY,EAAE,OAAO,EAAE,kBAAkB,EAAE;gBACnD,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE;aACrC;YACD,QAAQ;SACT;KACF,CAAC,CAAC;IACH,OAAO,QAAQ,CAAC;AAClB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"run.d.ts","sourceRoot":"","sources":["../../src/cli/run.ts"],"names":[],"mappings":"AAeA,MAAM,MAAM,OAAO,GAAG;IACpB,IAAI,EAAE,MAAM,EAAE,CAAC;CAChB,CAAC;AAEF;;GAEG;AACH,wBAAsB,GAAG,CAAC,OAAO,EAAE,OAAO,iBAkDzC"}
1
+ {"version":3,"file":"run.d.ts","sourceRoot":"","sources":["../../src/cli/run.ts"],"names":[],"mappings":"AAWA,MAAM,MAAM,OAAO,GAAG;IACpB,IAAI,EAAE,MAAM,EAAE,CAAC;CAChB,CAAC;AAEF;;GAEG;AACH,wBAAsB,GAAG,CAAC,OAAO,EAAE,OAAO,iBAsCzC"}