-
Notifications
You must be signed in to change notification settings - Fork 7
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
feat(cli): unbundle 3rd-party CLIs #434
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
packages/cli/src/lib/decorators/preconditions/binPreconditionsFactory.ts
Outdated
Show resolved
Hide resolved
packages/cli/src/lib/decorators/preconditions/binPreconditionsFactory.ts
Outdated
Show resolved
Hide resolved
packages/cli/src/lib/decorators/preconditions/binPreconditionsFactory.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💯 Nice job
packages/cli/src/lib/decorators/preconditions/binPreconditionsFactory.ts
Outdated
Show resolved
Hide resolved
This is a funny story. I'll start with the short version: Windows. The long one now: Node.JS rely on libuv/libuv for IO operations (which is fine!). However, libuv/libuv also does that: What this does, is 'if ENOENT is defined, then I set UV__ENOENT to its value, else, I set it to -4058' So, when a file is missing on Windows, we got a -4058 for errorCode, and 2 for POSIX. Well, Windows user can define ENOENT (or so I read) if they so desire . Which that the I'll double-check something tho on that given that 'code' is consistent it seems:
|
Proposed changes
Currently, a large part of the footprint of the CLI is caused by
@vue/cli
or@angular/cli
, orcreate-react-app
.Unbundling them solves the issue and also ensures that the user will have a smooth ride moving forward when using either of them.
Removed some unused branching in the preconditions factories and add support for auto-fix in precondition
Breaking changes
This is arguable. This could be considered a breaking change on
ui:create:angular
because we now have a new user interaction branching. However, I do not consider CI/CD usage of this command to be a use case we want to support. Therefore, I'll consider the breaking aspect on iff the input of the command changed (no), or if the output of the command changed (no)Testing
@angular/cli
is the tricky bit with the global install, and is not installed in the setup phase (which mean it'll therefore be installed by the preconditions and the Terminal manipulation.CDX-478