-
Notifications
You must be signed in to change notification settings - Fork 317
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
Node package manager improvements #9426
Conversation
Make more clear that these files host functions that are for any Node package manager, not just NPM specifically. Also rename the `NodePackageManager` enum to `NodePackageManagerType` to make room for another class that is more appropriate to use that name. Signed-off-by: Sebastian Schuberth <[email protected]>
Prepare for generalizing some code. Signed-off-by: Sebastian Schuberth <[email protected]>
Put code that is common to all Node package managers into an abstract base class to reduce code duplication and to ease upcoming changes. As some types are now exposed through the class hierarchy / constructor parameters, it is required to make them public. While at it, also perform some minor code alignments. Note that this reintroduction of a class hierarchy does not go against the idea of recently made changes to decouple the individual Node package manager implementations from each other: It is still the case that e.g. the PNPM implementation should not inherit from the NPM implementation. Signed-off-by: Sebastian Schuberth <[email protected]>
This avoids the need to pass the `managerName` as a parameter, and to have a top-level logger. Signed-off-by: Sebastian Schuberth <[email protected]>
Signed-off-by: Sebastian Schuberth <[email protected]>
2f44c7c
to
ab452ad
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #9426 +/- ##
============================================
- Coverage 68.07% 68.07% -0.01%
+ Complexity 1291 1285 -6
============================================
Files 249 249
Lines 8837 8827 -10
Branches 918 918
============================================
- Hits 6016 6009 -7
+ Misses 2435 2432 -3
Partials 386 386
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
@fviernau agreed privately to proceed with this without his review. |
This centralizes project creation which will ease an upcoming change.