From 2165d45a6a65a647478cf5b7b67b3bfd5cee5939 Mon Sep 17 00:00:00 2001 From: Huiwen Date: Mon, 2 Dec 2024 14:22:57 +0000 Subject: [PATCH] Make it build with leeway --- components/ide/jetbrains/toolbox/BUILD.yaml | 26 +++++++++++++++++++ .../ide/jetbrains/toolbox/build.gradle.kts | 2 ++ components/ide/jetbrains/toolbox/build.sh | 12 +++++++++ .../ide/jetbrains/toolbox/settings.gradle.kts | 4 +++ 4 files changed, 44 insertions(+) create mode 100644 components/ide/jetbrains/toolbox/BUILD.yaml create mode 100755 components/ide/jetbrains/toolbox/build.sh diff --git a/components/ide/jetbrains/toolbox/BUILD.yaml b/components/ide/jetbrains/toolbox/BUILD.yaml new file mode 100644 index 00000000000000..a9359e7cd90225 --- /dev/null +++ b/components/ide/jetbrains/toolbox/BUILD.yaml @@ -0,0 +1,26 @@ +packages: + - name: plugin-stable + type: generic + deps: + - components/supervisor-api/java:lib + - components/public-api/java:lib + srcs: + - "**/*.kt" + - "**/*.kts" + - src/main/resources/* + - gradle.properties + - gradlew + - gradle/* + - build.sh + env: + - JB_QUALIFIER=stable + - SDKMAN_DIR=/home/gitpod/.sdkman + config: + commands: + - - "bash" + - "-c" + - > + echo java=21.0.3.fx-zulu > .sdkmanrc + && source "$SDKMAN_DIR/bin/sdkman-init.sh" + && sdk env install + && ./build.sh diff --git a/components/ide/jetbrains/toolbox/build.gradle.kts b/components/ide/jetbrains/toolbox/build.gradle.kts index c3f02c4b64e150..12df842c6eda17 100644 --- a/components/ide/jetbrains/toolbox/build.gradle.kts +++ b/components/ide/jetbrains/toolbox/build.gradle.kts @@ -156,6 +156,7 @@ val copyPlugin by tasks.creating(Sync::class.java) { include("extension.json") include("dependencies.json") include("icon.svg") + include("icon-colored.svg") } into(targetDir) @@ -173,6 +174,7 @@ val pluginZip by tasks.creating(Zip::class) { } from("src/main/resources") { include("icon.svg") + include("icon-colored.svg") rename("icon.svg", "pluginIcon.svg") } archiveBaseName.set("$pluginId-$pluginVersion") diff --git a/components/ide/jetbrains/toolbox/build.sh b/components/ide/jetbrains/toolbox/build.sh new file mode 100755 index 00000000000000..8b11942e0bf0e0 --- /dev/null +++ b/components/ide/jetbrains/toolbox/build.sh @@ -0,0 +1,12 @@ +#!/bin/bash +# Copyright (c) 2024 Gitpod GmbH. All rights reserved. +# Licensed under the GNU Affero General Public License (AGPL). +# See License.AGPL.txt in the project root for license information. + +set -e + +JB_GP_VERSION=${1:-debug} + +./gradlew -PsupervisorApiProjectPath=components-supervisor-api-java--lib/ -PgitpodPublicApiProjectPath=components-public-api-java--lib/ -PenvironmentName="$JB_QUALIFIER" -Dgradle.user.home="/workspace/.gradle-tb-$JB_QUALIFIER" -Dplugin.verifier.home.dir="$HOME/.cache/pluginVerifier-tb-$JB_QUALIFIER" -PgitpodVersion="$JB_GP_VERSION" pluginZip + +# unzip ./build/distributions/io.gitpod.toolbox.gateway-0.0.1-dev.zip -d ./build diff --git a/components/ide/jetbrains/toolbox/settings.gradle.kts b/components/ide/jetbrains/toolbox/settings.gradle.kts index 9732826b70f69c..a82e354dc8a54a 100644 --- a/components/ide/jetbrains/toolbox/settings.gradle.kts +++ b/components/ide/jetbrains/toolbox/settings.gradle.kts @@ -1,3 +1,7 @@ +// Copyright (c) 2024 Gitpod GmbH. All rights reserved. +// Licensed under the GNU Affero General Public License (AGPL). +// See License.AGPL.txt in the project root for license information. + rootProject.name = "gitpod-toolbox-gateway" include(":supervisor-api")