-
Notifications
You must be signed in to change notification settings - Fork 287
feat(toolkit): Add notification for AWS Core plugin no longer required #6333
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| { | ||
| "type" : "feature", | ||
| "description" : "Removed dependency on the AWS Core plugin. AWS Toolkit no longer requires AWS Core to be installed." | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,54 @@ | ||
| // Copyright 2026 Amazon.com, Inc. or its affiliates. All Rights Reserved. | ||
| // SPDX-License-Identifier: Apache-2.0 | ||
|
|
||
| package software.aws.toolkits.jetbrains.core.notification | ||
|
|
||
| import com.intellij.ide.plugins.PluginManagerConfigurable | ||
| import com.intellij.ide.plugins.PluginManagerCore | ||
| import com.intellij.ide.util.PropertiesComponent | ||
| import com.intellij.notification.NotificationAction | ||
| import com.intellij.notification.NotificationGroupManager | ||
| import com.intellij.notification.NotificationType | ||
| import com.intellij.openapi.application.ApplicationManager | ||
| import com.intellij.openapi.extensions.PluginId | ||
| import com.intellij.openapi.options.ShowSettingsUtil | ||
| import com.intellij.openapi.project.Project | ||
| import com.intellij.openapi.startup.ProjectActivity | ||
| import software.aws.toolkits.resources.message | ||
|
|
||
| class AwsCorePluginNotice : ProjectActivity { | ||
|
Check warning on line 19 in plugins/toolkit/jetbrains-core/src/software/aws/toolkits/jetbrains/core/notification/AwsCorePluginNotice.kt
|
||
|
|
||
| override suspend fun execute(project: Project) { | ||
| if (ApplicationManager.getApplication().isUnitTestMode) return | ||
| if (PropertiesComponent.getInstance().getBoolean(IGNORE_PROMPT)) return | ||
| if (!PluginManagerCore.isPluginInstalled(PluginId.getId(CORE_PLUGIN_ID))) return | ||
|
|
||
| val notificationGroup = NotificationGroupManager.getInstance().getNotificationGroup("aws.toolkit_core_notice") | ||
| notificationGroup.createNotification( | ||
| message("aws.toolkit_core_notice.title"), | ||
| message("aws.toolkit_core_notice.message"), | ||
| NotificationType.INFORMATION | ||
| ) | ||
| .addAction( | ||
| NotificationAction.createSimpleExpiring(message("aws.toolkit_core_notice.manage_plugins")) { | ||
|
Check warning on line 32 in plugins/toolkit/jetbrains-core/src/software/aws/toolkits/jetbrains/core/notification/AwsCorePluginNotice.kt
|
||
github-advanced-security[bot] marked this conversation as resolved.
Fixed
Show fixed
Hide fixed
|
||
| ShowSettingsUtil.getInstance().showSettingsDialog( | ||
| project, | ||
| PluginManagerConfigurable::class.java | ||
|
Check warning on line 35 in plugins/toolkit/jetbrains-core/src/software/aws/toolkits/jetbrains/core/notification/AwsCorePluginNotice.kt
|
||
|
||
| ) { configurable: PluginManagerConfigurable -> | ||
|
Check warning on line 36 in plugins/toolkit/jetbrains-core/src/software/aws/toolkits/jetbrains/core/notification/AwsCorePluginNotice.kt
|
||
github-advanced-security[bot] marked this conversation as resolved.
Fixed
Show fixed
Hide fixed
|
||
| configurable.openInstalledTab(CORE_PLUGIN_NAME) | ||
|
Check warning on line 37 in plugins/toolkit/jetbrains-core/src/software/aws/toolkits/jetbrains/core/notification/AwsCorePluginNotice.kt
|
||
github-advanced-security[bot] marked this conversation as resolved.
Fixed
Show fixed
Hide fixed
|
||
| } | ||
| } | ||
| ) | ||
| .addAction( | ||
| NotificationAction.createSimpleExpiring(message("general.notification.action.hide_forever")) { | ||
| PropertiesComponent.getInstance().setValue(IGNORE_PROMPT, true) | ||
| } | ||
| ) | ||
| .notify(project) | ||
| } | ||
|
|
||
| companion object { | ||
| const val CORE_PLUGIN_ID = "aws.toolkit.core" | ||
| const val CORE_PLUGIN_NAME = "AWS Core" | ||
| const val IGNORE_PROMPT = "aws.toolkit_core_notice.dismissed" | ||
| } | ||
| } | ||
Uh oh!
There was an error while loading. Please reload this page.