Skip to content

Commit f3deb4b

Browse files
committed
The Whole bundle must be from the same repository
TODO: - Unsafe fallback option - Better file watcher (create events, watch the whole local repo) - Check how exceptions are handled while in checkers - Store matched stacktrace with the exception for highlighting
1 parent 6a22fb4 commit f3deb4b

File tree

8 files changed

+319
-207
lines changed

8 files changed

+319
-207
lines changed

src/main/kotlin/com/github/mr3zee/kotlinPlugins/KotlinPluginsConfigurable.kt

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -102,21 +102,6 @@ private class LocalState {
102102
}
103103

104104
class KotlinPluginsConfigurable(private val project: Project) : Configurable {
105-
companion object {
106-
@Volatile
107-
private var selectArtifactsInitially: Boolean = false
108-
109-
fun showArtifacts(project: Project) {
110-
selectArtifactsInitially = true
111-
ShowSettingsUtil.getInstance().showSettingsDialog(project, KotlinPluginsConfigurable::class.java)
112-
}
113-
114-
fun showGeneral(project: Project) {
115-
selectArtifactsInitially = false
116-
ShowSettingsUtil.getInstance().showSettingsDialog(project, KotlinPluginsConfigurable::class.java)
117-
}
118-
}
119-
120105
private val local: LocalState = LocalState()
121106

122107
private lateinit var repoTable: JBTable
@@ -319,9 +304,9 @@ class KotlinPluginsConfigurable(private val project: Project) : Configurable {
319304
val tabs = JBTabbedPane()
320305
tabs.addTab("General", generalContent)
321306
tabs.addTab("Artifacts", artifactsContent)
322-
if (selectArtifactsInitially) {
307+
if (KotlinPluginsConfigurableUtil.selectArtifactsInitially) {
323308
tabs.selectedIndex = 1
324-
selectArtifactsInitially = false
309+
KotlinPluginsConfigurableUtil.selectArtifactsInitially = false
325310
}
326311
rootPanel = JPanel(BorderLayout()).apply { add(tabs, BorderLayout.NORTH) }
327312

@@ -829,5 +814,20 @@ private class PluginsDialog(
829814
}
830815
}
831816

832-
val mavenRegex = "([\\w.]+):([\\w\\-]+)".toRegex()
833-
val pluginNameRegex = "[a-zA-Z0-9_-]+".toRegex()
817+
internal val mavenRegex = "([\\w.]+):([\\w\\-]+)".toRegex()
818+
internal val pluginNameRegex = "[a-zA-Z0-9_-]+".toRegex()
819+
820+
internal object KotlinPluginsConfigurableUtil {
821+
@Volatile
822+
var selectArtifactsInitially: Boolean = false
823+
824+
fun showArtifacts(project: Project) {
825+
selectArtifactsInitially = true
826+
ShowSettingsUtil.getInstance().showSettingsDialog(project, KotlinPluginsConfigurable::class.java)
827+
}
828+
829+
fun showGeneral(project: Project) {
830+
selectArtifactsInitially = false
831+
ShowSettingsUtil.getInstance().showSettingsDialog(project, KotlinPluginsConfigurable::class.java)
832+
}
833+
}

src/main/kotlin/com/github/mr3zee/kotlinPlugins/KotlinPluginsExternalSystemReloadBridge.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ class KotlinPluginsExternalSystemReloadBridgeService(
7272
init {
7373
// Subscribe to external system notifications for this project
7474
ExternalSystemProgressNotificationManager.getInstance()
75-
.addNotificationListener(listener, project)
75+
.addNotificationListener(listener, this)
7676
}
7777

7878
override fun dispose() {

src/main/kotlin/com/github/mr3zee/kotlinPlugins/KotlinPluginsIcons.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ package com.github.mr3zee.kotlinPlugins
22

33
import com.intellij.openapi.util.IconLoader
44

5-
@Suppress("unused")
65
object KotlinPluginsIcons {
76
val Logo = IconLoader.getIcon("/icons/logo.svg", javaClass)
87
}

0 commit comments

Comments
 (0)