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

Watch for added/removed local extensions #1482

Merged
merged 1 commit into from
Nov 24, 2020

Conversation

panuhorsmalahti
Copy link
Contributor

@panuhorsmalahti panuhorsmalahti commented Nov 23, 2020

  • If extension is copied to the extensions folder, it's dependencies are installed and it's loaded to the application. It's not enabled by default, however
  • If the extensions is added from the UI, we need to later implement automatic enabling for it
  • Extensions removal is also detected, but not completely implemented.
  • Extension classes were slightly refactored to have less responsibilities
  • Using chokidar to watch as it should be better than fs.watch
  • Tested on macOS only for now
  • Fixes Lens should notice added/removed extension folders #1461

@panuhorsmalahti panuhorsmalahti requested a review from a team November 23, 2020 09:49
Copy link
Contributor

@jakolehm jakolehm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

windowManager = WindowManager.getInstance<WindowManager>(proxyPort);
extensionLoader.initExtensions(await extensionManager.load()); // call after windowManager to see splash earlier

// call after windowManager to see splash earlier
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This reminded me that maybe we should keep splash visible until all extensions are loaded. Story for another PR.

@jakolehm jakolehm added area/extension Something to related to the extension api enhancement New feature or request labels Nov 23, 2020
@jakolehm jakolehm added this to the 4.0.0 milestone Nov 23, 2020
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com>
@panuhorsmalahti panuhorsmalahti merged commit c79cee0 into master Nov 24, 2020
@panuhorsmalahti panuhorsmalahti deleted the feature/extension-watcher branch November 24, 2020 08:48
@jakolehm jakolehm mentioned this pull request Nov 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/extension Something to related to the extension api enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Lens should notice added/removed extension folders
2 participants