-
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support file types from CLI args #11
Conversation
Rollback Files For Sweep
|
Apply Sweep Rules to your PR?
|
|
Let's fix the linter issue https://github.com/jellydn/cspell-tool/actions/runs/6540243952/job/17759818576?pr=11 $ eslint --ext .ts .
/home/runner/work/cspell-tool/cspell-tool/src/index.ts
[6](https://github.com/jellydn/cspell-tool/actions/runs/6540243952/job/17759818576?pr=11#step:5:7)4:34 error 'fileType' will evaluate to '[object Object]' when stringified @typescript-eslint/no-base-to-string
64:34 error Invalid type "{ value: string; label: string; }" of template literal expression @typescript-eslint/restrict-template-expressions
✖ 2 problems (2 errors, 0 warnings) |
🚀 Wrote ChangesDone. |
Let's fix linter issue https://github.com/jellydn/cspell-tool/actions/runs/6547644743/job/17780545802?pr=11 |
🚀 Wrote ChangesI wasn't able to make changes. This could be due to an unclear request or a bug in my code. |
PR Feedback: 👎
Description
This PR adds support for specifying file types from the command line interface (CLI) in the cspell-tool. Previously, the tool only supported a fixed set of file types (md, ts, json, lua). With this change, users can now specify the file types they want to check for spelling issues when running the tool.
Additionally, this PR introduces the use of the consola library to prompt the user for input. The same approach used in the consola library example provided by the user is implemented to prompt the user for the file types they want to check.
Summary of Changes
src/index.ts
to import the consola library and use it to prompt the user for file types to check.cmd
variable insrc/index.ts
to use the file types specified by the user when constructing the command to run cspell.consola
as a dependency inpackage.json
to enable the use of the consola library for prompting the user.Please review and merge this PR to enable the cspell-tool to support custom file types from the CLI.
Fixes #5.
🎉 Latest improvements to Sweep:
💡 To get Sweep to edit this pull request, you can: