in src/main/kotlin/org/jetbrains/mcpserverplugin/MCPServerStartupValidator.kt [167:220]
override suspend fun execute(project: Project) {
val notificationGroup = NotificationGroupManager.getInstance().getNotificationGroup(GROUP_ID)
val settingsService = service<PluginSettings>()
if (SystemInfo.isLinux) {
logger.info("No Claude Client on Linux, skipping validation")
return
}
if (!ClaudeConfigManager.isClaudeClientInstalled() && settingsService.state.shouldShowClaudeNotification) {
val notification = notificationGroup.createNotification(
"Claude Client is not installed",
NotificationType.INFORMATION
)
notification.addAction(NotificationAction.createSimpleExpiring("Open Installation Instruction") {
BrowserUtil.open("https://claude.ai/download")
})
notification.addAction(NotificationAction.createSimpleExpiring("Don't Show Again") {
settingsService.state.shouldShowClaudeNotification = false
notification.expire()
})
notification.notify(project)
}
val npxInstalled = isNpxInstalled()
if (settingsService.state.shouldShowNodeNotification && !npxInstalled) {
val notification = notificationGroup.createNotification(
"Node is not installed",
"MCP Server Proxy requires Node.js to be installed",
NotificationType.INFORMATION
)
notification.addAction(NotificationAction.createSimpleExpiring("Open Installation Instruction") {
BrowserUtil.open("https://nodejs.org/en/download/package-manager")
})
notification.addAction(NotificationAction.createSimpleExpiring("Don't Show Again") {
settingsService.state.shouldShowNodeNotification = false
notification.expire()
})
notification.notify(project)
}
if (ClaudeConfigManager.isClaudeClientInstalled() && npxInstalled && !ClaudeConfigManager.isProxyConfigured() && settingsService.state.shouldShowClaudeSettingsNotification) {
val notification = notificationGroup.createNotification(
"MCP Server Proxy is not configured",
NotificationType.INFORMATION
)
notification.addAction(NotificationAction.createSimpleExpiring("Install MCP Server Proxy") {
ClaudeConfigManager.modifyClaudeSettings()
})
notification.addAction(NotificationAction.createSimpleExpiring("Don't Show Again") {
settingsService.state.shouldShowClaudeSettingsNotification = false
notification.expire()
})
notification.notify(project)
}
}