Skip to content
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

Stack trace is printed if you specify unknown CLI options to analyze #112

Open
jpzwarte opened this issue Aug 19, 2021 · 2 comments
Open

Comments

@jpzwarte
Copy link

cem --help works fine

cem analyze --help doesn't:

(node:33622) UnhandledPromiseRejectionWarning: UNKNOWN_OPTION: Unknown option: --help
    at commandLineArgs (/Users/jeroenz/Projects/dna/core/node_modules/command-line-args/dist/index.js:1374:21)
    at getCliConfig (file:///Users/jeroenz/Projects/dna/core/node_modules/@custom-elements-manifest/analyzer/src/utils/cli.js:73:10)

Not just --help, but any property cem doesn't know about, so cem analyze --silent:

(node:33623) UnhandledPromiseRejectionWarning: UNKNOWN_OPTION: Unknown option: --silent
    at commandLineArgs (/Users/jeroenz/Projects/dna/core/node_modules/command-line-args/dist/index.js:1374:21)
    at getCliConfig (file:///Users/jeroenz/Projects/dna/core/node_modules/@custom-elements-manifest/analyzer/src/utils/cli.js:73:10)
@thepassle
Copy link
Member

cem analyze --help is kind of like saying npm install --help. What would you exactly expect to happen? To analyze, or output a help menu?

@jpzwarte
Copy link
Author

@thepassle output specific analyze help, or if there are no specific analyze options, output the generic help. But always output help when passing --help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants