-
-
Notifications
You must be signed in to change notification settings - Fork 23
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
Don’t throw exception if globs or file-paths to directories are given, but none are found #29
Comments
The error should really only be thrown if this was to be used programmatically where the user can then decide what to do, when used in a cli it should really just return nothing like most other clis do. |
@OmgImAlexis Hello! 👋 Welcome to the community & nice to meet you! I think you’re misunderstanding what I’m proposing and reiterating what I meant. For example ESLint also throws without input: $ eslint
eslint [options] file.js [file.js] [dir]
Basic configuration:
-c, --config path::String Use configuration from this file or shareable config
... ...and stylelint: $ stylelint
A mighty, modern CSS linter.
Usage: stylelint [input] [options]
Input: Files(s), glob(s), or nothing to use stdin. ...and I propose remark keeps doing so too. |
Could we please make the remark CLI behave just as other CLI's do when no input is given? |
Neither of those examples throw an error though and you're also comparing passing |
That’s why this issue is here and the "needs pr" label is attached 🤷♂️ @OmgImAlexis “They're not the same thing as shown by the error” is what this issue is solving, and what I’ve tried to explain three times now... |
Currently there’s a “No input” error:
λ remark . -qfo Error: No input at stdin (/Users/niftylettuce/Public/lad/template/node_modules/unified-engine/lib/file-set-pipeline/stdin.js:30:10) ...
...but as there’s actually “input”, the error is weird.
I think the exception should still be thrown if nothing is passed in.
Supersedes remarkjs/remark#294.
The text was updated successfully, but these errors were encountered: