From 395b075b15cfe577c060fd37b60d1c2a8fbb4294 Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Thu, 30 Jun 2022 00:52:31 +0300 Subject: [PATCH 01/11] Upgrade GW platform to latest EAP, i.e 2022.x - also increase the major version due to backward incompatible changes introduced by the new GW platform (see semver for how to increase the version) --- gradle.properties | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/gradle.properties b/gradle.properties index 90215cd9..d4f89029 100644 --- a/gradle.properties +++ b/gradle.properties @@ -3,16 +3,16 @@ pluginGroup=com.coder.gateway pluginName=coder-gateway # SemVer format -> https://semver.org -pluginVersion=1.0.0 +pluginVersion=2.0.0 # See https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html # for insight into build numbers and IntelliJ Platform versions. -pluginSinceBuild=213 -pluginUntilBuild=221.* +pluginSinceBuild=222.* +pluginUntilBuild=222.* # IntelliJ Platform Properties -> https://github.com/JetBrains/gradle-intellij-plugin#intellij-platform-properties # Gateway available build versions https://www.jetbrains.com/intellij-repository/snapshots and https://www.jetbrains.com/intellij-repository/releases platformType=GW -platformVersion=221.5921.22-CUSTOM-SNAPSHOT -instrumentationCompiler=221.5921.22 +platformVersion=222.3244.1-CUSTOM-SNAPSHOT +instrumentationCompiler=222.3244.1-CUSTOM-SNAPSHOT platformDownloadSources=true # Plugin Dependencies -> https://plugins.jetbrains.com/docs/intellij/plugin-dependencies.html # Example: platformPlugins = com.intellij.java, com.jetbrains.php:203.4449.22 From 8d81fbafa601d35274e362ea4a45d19e6e82b03c Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Fri, 1 Jul 2022 00:57:23 +0300 Subject: [PATCH 02/11] Build with java 17 --- .github/workflows/build.yml | 2 +- build.gradle.kts | 5 +++++ gradle.properties | 4 ++-- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 7deb459e..9cc29419 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -46,7 +46,7 @@ jobs: uses: actions/setup-java@v3 with: distribution: zulu - java-version: 11 + java-version: 17 cache: gradle # Set environment variables diff --git a/build.gradle.kts b/build.gradle.kts index 817ff135..7af754b1 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -92,6 +92,11 @@ tasks { compilerVersion.set(properties("instrumentationCompiler")) } + // TODO - this fails with linkage error, remove when it works + buildSearchableOptions { + isEnabled = false + } + patchPluginXml { version.set(properties("pluginVersion")) sinceBuild.set(properties("pluginSinceBuild")) diff --git a/gradle.properties b/gradle.properties index d4f89029..d540c69b 100644 --- a/gradle.properties +++ b/gradle.properties @@ -17,8 +17,8 @@ platformDownloadSources=true # Plugin Dependencies -> https://plugins.jetbrains.com/docs/intellij/plugin-dependencies.html # Example: platformPlugins = com.intellij.java, com.jetbrains.php:203.4449.22 platformPlugins= -# Java language level used to compile sources and to generate the files for - Java 11 is required since 2020.3 -javaVersion=11 +# Java language level used to compile sources and to generate the files for - Java 17 is required since 2022.2 +javaVersion=17 # Gradle Releases -> https://github.com/gradle/gradle/releases gradleVersion=7.4 # Opt-out flag for bundling Kotlin standard library. From c074347d8e8a6d4be0293ef2e87d11d897782962 Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Fri, 1 Jul 2022 01:00:26 +0300 Subject: [PATCH 03/11] Adapt code to the new SSH API - the guessing the OS in the fallback method is now done by the SSH command executor - the download link to a product (ex: IntelliJ) is now wrapped in a more complex model (i.e. Download) - IdeWithStatus also changed --- .../coder/gateway/CoderGatewayConnectionProvider.kt | 6 +++--- .../views/steps/CoderLocateRemoteProjectStepView.kt | 11 ++++++----- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/main/kotlin/com/coder/gateway/CoderGatewayConnectionProvider.kt b/src/main/kotlin/com/coder/gateway/CoderGatewayConnectionProvider.kt index 9214529f..c74dee0c 100644 --- a/src/main/kotlin/com/coder/gateway/CoderGatewayConnectionProvider.kt +++ b/src/main/kotlin/com/coder/gateway/CoderGatewayConnectionProvider.kt @@ -14,11 +14,11 @@ import com.intellij.ssh.config.unified.SshConfig import com.jetbrains.gateway.api.ConnectionRequestor import com.jetbrains.gateway.api.GatewayConnectionHandle import com.jetbrains.gateway.api.GatewayConnectionProvider +import com.jetbrains.gateway.ssh.Download import com.jetbrains.gateway.ssh.IdeInfo import com.jetbrains.gateway.ssh.IntelliJPlatformProduct import com.jetbrains.gateway.ssh.SshCommandsExecutor import com.jetbrains.gateway.ssh.SshDeployFlowUtil -import com.jetbrains.gateway.ssh.SshDownloadMethod import com.jetbrains.gateway.ssh.SshMultistagePanelContext import com.jetbrains.rd.util.lifetime.LifetimeDefinition import kotlinx.coroutines.launch @@ -71,8 +71,7 @@ class CoderGatewayConnectionProvider : GatewayConnectionProvider { sshConfig = sshConfiguration remoteProjectPath = projectPath remoteCommandsExecutor = SshCommandsExecutor.Companion.create(credentials) - downloadMethod = SshDownloadMethod.CustomizedLink - customDownloadLink = ideDownloadLink + download = Download.fromJson(ideDownloadLink) ide = ideConfig } launch { @@ -98,6 +97,7 @@ class CoderGatewayConnectionProvider : GatewayConnectionProvider { ) return object : GatewayConnectionHandle(clientLifetime) { + @Deprecated("Implement customComponentProvider instead to provide better UI/UX without default controls") override fun createComponent(): JComponent { return CoderGatewayConnectionComponent(clientLifetime, coderWorkspaceHostname) } diff --git a/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt b/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt index 4fcda058..6218f006 100644 --- a/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt +++ b/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt @@ -33,7 +33,7 @@ import com.jetbrains.gateway.ssh.DeployTargetOS.OSKind import com.jetbrains.gateway.ssh.IdeStatus import com.jetbrains.gateway.ssh.IdeWithStatus import com.jetbrains.gateway.ssh.IntelliJPlatformProduct -import com.jetbrains.gateway.ssh.guessOs +import com.jetbrains.gateway.ssh.SshCommandsExecutor import kotlinx.coroutines.CoroutineScope import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.cancel @@ -116,11 +116,12 @@ class CoderLocateRemoteProjectStepView(private val disableNextAction: () -> Unit logger.info("Retrieving available IDE's for ${selectedWorkspace.name} workspace...") val workspaceOS = if (selectedWorkspace.agentOS != null && selectedWorkspace.agentArch != null) withContext(Dispatchers.IO) { toDeployedOS(selectedWorkspace.agentOS, selectedWorkspace.agentArch) } else withContext(Dispatchers.IO) { try { - RemoteCredentialsHolder().apply { + val credentialsHolder = RemoteCredentialsHolder().apply { setHost("coder.${selectedWorkspace.name}") userName = "coder" authType = AuthType.OPEN_SSH - }.guessOs + } + SshCommandsExecutor.Companion.create(credentialsHolder).guessOs() } catch (e: Exception) { logger.error("Could not resolve any IDE for workspace ${selectedWorkspace.name}. Reason: $e") null @@ -141,7 +142,7 @@ class CoderLocateRemoteProjectStepView(private val disableNextAction: () -> Unit IntelliJPlatformProduct.values() .filter { it.showInGateway } .flatMap { CachingProductsJsonWrapper.getAvailableIdes(it, workspaceOS) } - .map { ide -> IdeWithStatus(ide.product, ide.buildNumber, IdeStatus.DOWNLOAD, ide.downloadLink, ide.presentableVersion) } + .map { ide -> IdeWithStatus(ide.product, ide.buildNumber, IdeStatus.DOWNLOAD, ide.download, null, ide.presentableVersion) } } if (idesWithStatus.isEmpty()) { @@ -187,7 +188,7 @@ class CoderLocateRemoteProjectStepView(private val disableNextAction: () -> Unit "project_path" to tfProject.text, "ide_product_code" to selectedIDE.product.productCode, "ide_build_number" to selectedIDE.buildNumber, - "ide_download_link" to selectedIDE.source, + "ide_download_link" to selectedIDE.download!!.toJson(), "web_terminal_link" to "${terminalLink.url}" ) ) From 8aaf274192b770c6ac8941a59365e3b74de530c4 Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Fri, 1 Jul 2022 01:03:17 +0300 Subject: [PATCH 04/11] Release builds should be done with java 17 as well --- .github/workflows/release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d8d8848e..743314c3 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -19,12 +19,12 @@ jobs: with: ref: ${{ github.event.release.tag_name }} - # Setup Java 11 environment for the next steps + # Setup Java 17 environment for the next steps - name: Setup Java uses: actions/setup-java@v2 with: distribution: zulu - java-version: 11 + java-version: 17 cache: gradle # Set environment variables From f3af371470984c97a20c6165f638ae6193ef0643 Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Mon, 11 Jul 2022 23:09:07 +0300 Subject: [PATCH 05/11] Use the latest Gateway snapshot build - also increase the minimum version to the new build - this build is supposed to fix https://youtrack.jetbrains.com/issue/IDEA-297742 --- gradle.properties | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gradle.properties b/gradle.properties index d540c69b..95b4a134 100644 --- a/gradle.properties +++ b/gradle.properties @@ -6,13 +6,13 @@ pluginName=coder-gateway pluginVersion=2.0.0 # See https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html # for insight into build numbers and IntelliJ Platform versions. -pluginSinceBuild=222.* +pluginSinceBuild=222.3345.1 pluginUntilBuild=222.* # IntelliJ Platform Properties -> https://github.com/JetBrains/gradle-intellij-plugin#intellij-platform-properties # Gateway available build versions https://www.jetbrains.com/intellij-repository/snapshots and https://www.jetbrains.com/intellij-repository/releases platformType=GW -platformVersion=222.3244.1-CUSTOM-SNAPSHOT -instrumentationCompiler=222.3244.1-CUSTOM-SNAPSHOT +platformVersion=222.3345.1-CUSTOM-SNAPSHOT +instrumentationCompiler=222.3345.1-CUSTOM-SNAPSHOT platformDownloadSources=true # Plugin Dependencies -> https://plugins.jetbrains.com/docs/intellij/plugin-dependencies.html # Example: platformPlugins = com.intellij.java, com.jetbrains.php:203.4449.22 From 9651a17dbbbcd69e4c85e21978ff712116dfb0ac Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Wed, 13 Jul 2022 01:21:10 +0300 Subject: [PATCH 06/11] Fix: migrate to new API - the host executor and it's utilities like `guessOs` are now under a `host accessor` - ssh context is also changed - all params are now grouped under a `host deploy inputs` wrapper. --- .../gateway/CoderGatewayConnectionProvider.kt | 79 +++++++++---------- .../steps/CoderLocateRemoteProjectStepView.kt | 22 +++--- 2 files changed, 50 insertions(+), 51 deletions(-) diff --git a/src/main/kotlin/com/coder/gateway/CoderGatewayConnectionProvider.kt b/src/main/kotlin/com/coder/gateway/CoderGatewayConnectionProvider.kt index c74dee0c..e963a3fd 100644 --- a/src/main/kotlin/com/coder/gateway/CoderGatewayConnectionProvider.kt +++ b/src/main/kotlin/com/coder/gateway/CoderGatewayConnectionProvider.kt @@ -4,31 +4,34 @@ package com.coder.gateway import com.coder.gateway.models.RecentWorkspaceConnection import com.coder.gateway.services.CoderRecentWorkspaceConnectionsService -import com.coder.gateway.views.CoderGatewayConnectionComponent import com.intellij.openapi.components.service import com.intellij.openapi.diagnostic.Logger import com.intellij.openapi.rd.util.launchUnderBackgroundProgress import com.intellij.remote.AuthType import com.intellij.remote.RemoteCredentialsHolder import com.intellij.ssh.config.unified.SshConfig +import com.intellij.ssh.config.unified.SshConfigManager import com.jetbrains.gateway.api.ConnectionRequestor import com.jetbrains.gateway.api.GatewayConnectionHandle import com.jetbrains.gateway.api.GatewayConnectionProvider -import com.jetbrains.gateway.ssh.Download +import com.jetbrains.gateway.ssh.HighLevelHostAccessor +import com.jetbrains.gateway.ssh.HostDeployInputs import com.jetbrains.gateway.ssh.IdeInfo import com.jetbrains.gateway.ssh.IntelliJPlatformProduct -import com.jetbrains.gateway.ssh.SshCommandsExecutor import com.jetbrains.gateway.ssh.SshDeployFlowUtil import com.jetbrains.gateway.ssh.SshMultistagePanelContext +import com.jetbrains.gateway.ssh.deploy.DeployTargetInfo.DeployWithDownload import com.jetbrains.rd.util.lifetime.LifetimeDefinition import kotlinx.coroutines.launch +import java.net.URI import java.time.Duration import java.time.LocalDateTime import java.time.format.DateTimeFormatter -import javax.swing.JComponent class CoderGatewayConnectionProvider : GatewayConnectionProvider { private val recentConnectionsService = service() + private val sshConfigService = service() + private val connections = mutableSetOf() private val localTimeFormatter = DateTimeFormatter.ofPattern("yyyy-MMM-dd HH:mm") @@ -46,62 +49,54 @@ class CoderGatewayConnectionProvider : GatewayConnectionProvider { logger.warn("There is already a connection started on ${connection.workspaceHostname}") return null } - val clientLifetime = LifetimeDefinition() - - val credentials = RemoteCredentialsHolder().apply { - setHost(coderWorkspaceHostname) - userName = "coder" - authType = AuthType.OPEN_SSH - } - val sshConfiguration = SshConfig(true).apply { setHost(coderWorkspaceHostname) setUsername("coder") + port = 22 authType = AuthType.OPEN_SSH } - val ideConfig = IdeInfo( - product = IntelliJPlatformProduct.fromProductCode(ideProductCode)!!, - buildNumber = ideBuildNumber - ) - + val clientLifetime = LifetimeDefinition() clientLifetime.launchUnderBackgroundProgress("Coder Gateway Deploy", canBeCancelled = true, isIndeterminate = true, project = null) { - val context = SshMultistagePanelContext().apply { - deploy = true - sshConfig = sshConfiguration - remoteProjectPath = projectPath - remoteCommandsExecutor = SshCommandsExecutor.Companion.create(credentials) - download = Download.fromJson(ideDownloadLink) - ide = ideConfig - } + val context = SshMultistagePanelContext( + HostDeployInputs.FullySpecified( + remoteProjectPath = projectPath, + deployTarget = DeployWithDownload( + URI(ideDownloadLink), + null, + IdeInfo( + product = IntelliJPlatformProduct.fromProductCode(ideProductCode)!!, + buildNumber = ideBuildNumber + ) + ), + remoteInfo = HostDeployInputs.WithDeployedWorker( + HighLevelHostAccessor.create( + RemoteCredentialsHolder().apply { + setHost(coderWorkspaceHostname) + userName = "coder" + port = 22 + authType = AuthType.OPEN_SSH + }, + true + ), + HostDeployInputs.WithHostInfo(sshConfiguration) + ) + ) + ) launch { - @Suppress("UnstableApiUsage") - SshDeployFlowUtil.fullDeployCycle( - clientLifetime, - context, - Duration.ofMinutes(10) + @Suppress("UnstableApiUsage") SshDeployFlowUtil.fullDeployCycle( + clientLifetime, context, Duration.ofMinutes(10) ) } } recentConnectionsService.addRecentConnection( RecentWorkspaceConnection( - coderWorkspaceHostname, - projectPath, - localTimeFormatter.format(LocalDateTime.now()), - ideProductCode, - ideBuildNumber, - ideDownloadLink, - webTerminalLink, + coderWorkspaceHostname, projectPath, localTimeFormatter.format(LocalDateTime.now()), ideProductCode, ideBuildNumber, ideDownloadLink, webTerminalLink ) ) return object : GatewayConnectionHandle(clientLifetime) { - @Deprecated("Implement customComponentProvider instead to provide better UI/UX without default controls") - override fun createComponent(): JComponent { - return CoderGatewayConnectionComponent(clientLifetime, coderWorkspaceHostname) - } - override fun getTitle(): String { return "Connection to Coder Workspaces" } diff --git a/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt b/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt index 6218f006..a7d7c6b2 100644 --- a/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt +++ b/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt @@ -30,10 +30,11 @@ import com.jetbrains.gateway.ssh.CachingProductsJsonWrapper import com.jetbrains.gateway.ssh.DeployTargetOS import com.jetbrains.gateway.ssh.DeployTargetOS.OSArch import com.jetbrains.gateway.ssh.DeployTargetOS.OSKind +import com.jetbrains.gateway.ssh.HighLevelHostAccessor import com.jetbrains.gateway.ssh.IdeStatus import com.jetbrains.gateway.ssh.IdeWithStatus import com.jetbrains.gateway.ssh.IntelliJPlatformProduct -import com.jetbrains.gateway.ssh.SshCommandsExecutor +import com.jetbrains.gateway.ssh.deploy.guessOs import kotlinx.coroutines.CoroutineScope import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.cancel @@ -121,7 +122,10 @@ class CoderLocateRemoteProjectStepView(private val disableNextAction: () -> Unit userName = "coder" authType = AuthType.OPEN_SSH } - SshCommandsExecutor.Companion.create(credentialsHolder).guessOs() + HighLevelHostAccessor.create( + credentialsHolder, + true + ).hostCommandExecutor.guessOs() } catch (e: Exception) { logger.error("Could not resolve any IDE for workspace ${selectedWorkspace.name}. Reason: $e") null @@ -159,20 +163,20 @@ class CoderLocateRemoteProjectStepView(private val disableNextAction: () -> Unit return when (os) { OS.LINUX -> when (arch) { Arch.AMD64 -> DeployTargetOS(OSKind.Linux, OSArch.X86_64) - Arch.ARM64 -> DeployTargetOS(OSKind.Linux, OSArch.Aarch64) - Arch.ARMV7 -> DeployTargetOS(OSKind.Linux, OSArch.Unknown) + Arch.ARM64 -> DeployTargetOS(OSKind.Linux, OSArch.ARM_64) + Arch.ARMV7 -> DeployTargetOS(OSKind.Linux, OSArch.UNKNOWN) } OS.WINDOWS -> when (arch) { Arch.AMD64 -> DeployTargetOS(OSKind.Windows, OSArch.X86_64) - Arch.ARM64 -> DeployTargetOS(OSKind.Windows, OSArch.Aarch64) - Arch.ARMV7 -> DeployTargetOS(OSKind.Windows, OSArch.Unknown) + Arch.ARM64 -> DeployTargetOS(OSKind.Windows, OSArch.ARM_64) + Arch.ARMV7 -> DeployTargetOS(OSKind.Windows, OSArch.UNKNOWN) } OS.MAC -> when (arch) { Arch.AMD64 -> DeployTargetOS(OSKind.MacOs, OSArch.X86_64) - Arch.ARM64 -> DeployTargetOS(OSKind.MacOs, OSArch.Aarch64) - Arch.ARMV7 -> DeployTargetOS(OSKind.MacOs, OSArch.Unknown) + Arch.ARM64 -> DeployTargetOS(OSKind.MacOs, OSArch.ARM_64) + Arch.ARMV7 -> DeployTargetOS(OSKind.MacOs, OSArch.UNKNOWN) } } } @@ -188,7 +192,7 @@ class CoderLocateRemoteProjectStepView(private val disableNextAction: () -> Unit "project_path" to tfProject.text, "ide_product_code" to selectedIDE.product.productCode, "ide_build_number" to selectedIDE.buildNumber, - "ide_download_link" to selectedIDE.download!!.toJson(), + "ide_download_link" to selectedIDE.download!!.link, "web_terminal_link" to "${terminalLink.url}" ) ) From 7f3c5ed250e92596fcce767d84aaadd4428e6c9f Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Wed, 13 Jul 2022 22:51:31 +0300 Subject: [PATCH 07/11] chore: upgraded minimum supported Gateway version to latest build --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 95b4a134..caf852ce 100644 --- a/gradle.properties +++ b/gradle.properties @@ -11,7 +11,7 @@ pluginUntilBuild=222.* # IntelliJ Platform Properties -> https://github.com/JetBrains/gradle-intellij-plugin#intellij-platform-properties # Gateway available build versions https://www.jetbrains.com/intellij-repository/snapshots and https://www.jetbrains.com/intellij-repository/releases platformType=GW -platformVersion=222.3345.1-CUSTOM-SNAPSHOT +platformVersion=222.3345.26-CUSTOM-SNAPSHOT instrumentationCompiler=222.3345.1-CUSTOM-SNAPSHOT platformDownloadSources=true # Plugin Dependencies -> https://plugins.jetbrains.com/docs/intellij/plugin-dependencies.html From 37415da4d280a95aa11e22a12f2f7e91afc3e6f1 Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Wed, 13 Jul 2022 22:51:56 +0300 Subject: [PATCH 08/11] Update changelog --- CHANGELOG.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 41075e53..204674a4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,14 @@ ## [Unreleased] ### Added +- support for Gateway 2022.2 + +### Changed +- Java 17 is now required to run the plugin +- adapted the code to the new SSH API provided by Gateway + +## [1.0.0] +### Added - initial scaffold for Gateway plugin - browser based authentication on Coder environments - REST client for Coder V2 public API From 9c334bcc628f8420a9662af4b043774b0e6ff298 Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Wed, 20 Jul 2022 00:04:38 +0300 Subject: [PATCH 09/11] Use new build --- gradle.properties | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gradle.properties b/gradle.properties index caf852ce..53346998 100644 --- a/gradle.properties +++ b/gradle.properties @@ -6,13 +6,13 @@ pluginName=coder-gateway pluginVersion=2.0.0 # See https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html # for insight into build numbers and IntelliJ Platform versions. -pluginSinceBuild=222.3345.1 +pluginSinceBuild=222.3490 pluginUntilBuild=222.* # IntelliJ Platform Properties -> https://github.com/JetBrains/gradle-intellij-plugin#intellij-platform-properties # Gateway available build versions https://www.jetbrains.com/intellij-repository/snapshots and https://www.jetbrains.com/intellij-repository/releases platformType=GW -platformVersion=222.3345.26-CUSTOM-SNAPSHOT -instrumentationCompiler=222.3345.1-CUSTOM-SNAPSHOT +platformVersion=222.3490-CUSTOM-SNAPSHOT +instrumentationCompiler=222.3490-CUSTOM-SNAPSHOT platformDownloadSources=true # Plugin Dependencies -> https://plugins.jetbrains.com/docs/intellij/plugin-dependencies.html # Example: platformPlugins = com.intellij.java, com.jetbrains.php:203.4449.22 From 28db38b0c4fa7882305b0a43b14f0c166a570454 Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Wed, 20 Jul 2022 00:05:19 +0300 Subject: [PATCH 10/11] Update the API calls --- .../gateway/views/steps/CoderLocateRemoteProjectStepView.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt b/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt index a7d7c6b2..f95b3685 100644 --- a/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt +++ b/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt @@ -146,7 +146,7 @@ class CoderLocateRemoteProjectStepView(private val disableNextAction: () -> Unit IntelliJPlatformProduct.values() .filter { it.showInGateway } .flatMap { CachingProductsJsonWrapper.getAvailableIdes(it, workspaceOS) } - .map { ide -> IdeWithStatus(ide.product, ide.buildNumber, IdeStatus.DOWNLOAD, ide.download, null, ide.presentableVersion) } + .map { ide -> IdeWithStatus(ide.product, ide.buildNumber, IdeStatus.DOWNLOAD, ide.download, null, ide.presentableVersion, ide.remoteDevType) } } if (idesWithStatus.isEmpty()) { From 263bce24286af57e475299552f956953f19ca0a9 Mon Sep 17 00:00:00 2001 From: Ioan Faur Date: Mon, 1 Aug 2022 23:00:46 +0300 Subject: [PATCH 11/11] Revert previous commit - seems like Beta still points to an older snapshot even though 222.3490 is available on the snapshot repo --- gradle.properties | 6 +++--- .../gateway/views/steps/CoderLocateRemoteProjectStepView.kt | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/gradle.properties b/gradle.properties index 53346998..77f868d5 100644 --- a/gradle.properties +++ b/gradle.properties @@ -6,13 +6,13 @@ pluginName=coder-gateway pluginVersion=2.0.0 # See https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html # for insight into build numbers and IntelliJ Platform versions. -pluginSinceBuild=222.3490 +pluginSinceBuild=222.3345.108 pluginUntilBuild=222.* # IntelliJ Platform Properties -> https://github.com/JetBrains/gradle-intellij-plugin#intellij-platform-properties # Gateway available build versions https://www.jetbrains.com/intellij-repository/snapshots and https://www.jetbrains.com/intellij-repository/releases platformType=GW -platformVersion=222.3490-CUSTOM-SNAPSHOT -instrumentationCompiler=222.3490-CUSTOM-SNAPSHOT +platformVersion=222.3345.108-CUSTOM-SNAPSHOT +instrumentationCompiler=222.3345.108-CUSTOM-SNAPSHOT platformDownloadSources=true # Plugin Dependencies -> https://plugins.jetbrains.com/docs/intellij/plugin-dependencies.html # Example: platformPlugins = com.intellij.java, com.jetbrains.php:203.4449.22 diff --git a/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt b/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt index f95b3685..a7d7c6b2 100644 --- a/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt +++ b/src/main/kotlin/com/coder/gateway/views/steps/CoderLocateRemoteProjectStepView.kt @@ -146,7 +146,7 @@ class CoderLocateRemoteProjectStepView(private val disableNextAction: () -> Unit IntelliJPlatformProduct.values() .filter { it.showInGateway } .flatMap { CachingProductsJsonWrapper.getAvailableIdes(it, workspaceOS) } - .map { ide -> IdeWithStatus(ide.product, ide.buildNumber, IdeStatus.DOWNLOAD, ide.download, null, ide.presentableVersion, ide.remoteDevType) } + .map { ide -> IdeWithStatus(ide.product, ide.buildNumber, IdeStatus.DOWNLOAD, ide.download, null, ide.presentableVersion) } } if (idesWithStatus.isEmpty()) {