-
Notifications
You must be signed in to change notification settings - Fork 17
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
[WIP] Separate commands implementation from specific CLI args parser. #1605
base: trunk
Are you sure you want to change the base?
Conversation
…an issue with insance fields: instance fields of a derived class are defined after super() returns, the base class's constructor does not have access to the derived class's fields.
This looks pretty cool. I'm not totally sold on the When you feel like this is a good enough shape / structure, can you P2 it (maybe just a follow-up comment to @sjinks discovery post) so we can get perspectives from the team? |
I get your concern, the flip side is that we get a nice tree structure that's easy to recursively iterate on. From the structure standpoint I think @sjinks's idea (at least my interpretation of it) is something like this: import { OneChildCommand } from '../commands/one-child-command';
import { TwoChildCommand } from '../commands/two-child-command';
class ParentCommand {
childCommands: [
OneChildCommand,
TwoChildCommand
] So the unwieldiness part might be mitigated. But that's foremost on my mind too, we'll see how it goes. Re: p2 - absolutely, once we have something more palatable to show. |
…true, this property would control whether auth is needed, and if so will call the authenticate method, which is currently almost verbatim copy-pasta from bin/vip.js
Quality Gate failedFailed conditions 25.0% Duplication on New Code (required ≤ 3%) See analysis details on SonarCloud Catch issues before they fail your Quality Gate with our IDE extension SonarLint |
Quality Gate failedFailed conditions |
This pull request has been marked stale because it has been open for 60 days with no activity. If there is no activity within 7 days, it will be closed. This is an automation to keep pull requests manageable and actionable and is not a comment on the quality of this pull request nor on the work done so far. Closed PRs are still valuable to the project and their branches are preserved. |
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.OpenSSF Scorecard
Scanned Manifest Filespackage.json
|
Quality Gate failedFailed conditions |
Description
This is the first step of the first step of removal of yargs in favor of commander.
The general idea is to decouple commands from the specific arguments parser.
The implementation consists of two pieces:
Missing pieces
Pull request checklist
New release checklist
Steps to Test
Outline the steps to test and verify the PR here.
Example:
npm run build
./dist/lib/command.js