-
Notifications
You must be signed in to change notification settings - Fork 1
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
refactor: cache project context in toolbox to avoid passing it everywhere #115
base: main
Are you sure you want to change the base?
Conversation
toolbox.interactive.surveyStep( | ||
'Created snapshot of project state before execution.' | ||
) | ||
|
||
context.selectedOptions = await getSelectedOptions(toolbox) | ||
toolbox.context.selectedOptions = await getSelectedOptions(toolbox) |
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.
I'd prefer a setter here and possibly in other places getter instead of just toolbox.context.variable -> so noone is tempted to write (override) something
packageManager = LOCK_FILE_TO_MANAGER[lockFiles[0]] | ||
} | ||
|
||
return packageManager as PackageManager |
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.
I wonder if we couldn't check it somhow to avoid casting?
Resolves #43