flutter / flutter-intellij

Flutter Plugin for IntelliJ
https://flutter.dev/using-ide
BSD 3-Clause "New" or "Revised" License
1.97k stars 316 forks source link

support for IntelliJ dynamic plugins #4527

Open devoncarew opened 4 years ago

devoncarew commented 4 years ago

We should add support to the Flutter plugin for IntelliJ's new dynamic plugins:

https://www.jetbrains.org/intellij/sdk/docs/basics/plugin_structure/dynamic_plugins.html

I'm not sure of the scope of the work here.

stevemessick commented 4 years ago

I think we're gated on Android Studio supporting it. Or we could split IntelliJ and Android Studio plugin into separate distros.

stevemessick commented 3 years ago

4.1 supports this. We should get started.

stevemessick commented 3 years ago

According to the JetBrains plugin verifier:

Plugin cannot be loaded/unloaded without IDE restart because it declares non-dynamic extensions: com.android.moduleDescriptionProvider, com.android.project.projectsystem Plugin cannot be loaded/unloaded without IDE restart because it declares a group without 'id' specified

We will be able to delete the com.android.moduleDescriptionProvider when Android Studio 4.2 becomes the stable release.

We cannot delete the com.android.project.projectsystem as it is required to show the Project Structure menu. We'll have to rely on Android Studio making it dynamic.

Our pop-menus have <group> with no id but I think that will be easy to change.

We should use com.intellij.ide.plugins.DynamicPluginListener to either prevent reloading while an app is running, or ask the user if it is OK to restart it.

Most of the plugin downloads are for Android Studio. We'll keep this on hold until Android Studio has made that extension dynamic.

stevemessick commented 3 years ago

Also saw this in the log file: plugin io.flutter is not unload-safe because of extension to non-dynamic EP com.intellij.defaultLiveTemplatesProvider

stevemessick commented 2 years ago

This work requires #6076 to be fixed.

The com.android.project.projectsystem EP is no longer required.

stevemessick commented 2 years ago

cc @jacob314