Publish Kobweb artifacts #525
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish Kobweb artifacts | |
on: | |
workflow_dispatch: | |
inputs: | |
repo-gcloud: | |
type: boolean | |
description: "Repository: GCloud" | |
default: true | |
repo-sonatype: | |
type: boolean | |
description: "Repository: Sonatype" | |
default: true | |
repo-gradle-portal: | |
type: boolean | |
description: "Repository: Gradle Plugin Portal (release only)" | |
default: false | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
env: | |
# See: https://docs.gradle.org/current/userguide/signing_plugin.html#sec:in-memory-keys | |
ORG_GRADLE_PROJECT_signingKey: ${{ secrets.VARABYTE_SIGNING_KEY }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-java@v4 | |
with: | |
distribution: temurin | |
java-version: 11 | |
- name: Setup Gradle | |
uses: gradle/actions/setup-gradle@v4 | |
with: | |
build-scan-publish: true | |
build-scan-terms-of-use-url: "https://gradle.com/help/legal-terms-of-use" | |
build-scan-terms-of-use-agree: "yes" | |
cache-read-only: false | |
- name: Add secret Gradle properties | |
env: | |
GRADLE_PROPERTIES: ${{ secrets.VARABYTE_GRADLE_PROPERTIES }} | |
run: | | |
mkdir -p ~/.gradle/ | |
echo "GRADLE_USER_HOME=${HOME}/.gradle" >> $GITHUB_ENV | |
echo "${GRADLE_PROPERTIES}" > ~/.gradle/gradle.properties | |
- name: Publish Kobweb artifacts (GCloud) | |
if: inputs.repo-gcloud | |
run: ./gradlew publishAllPublicationsToGCloudMavenRepository | |
- name: Publish Kobweb artifacts (Sonatype) | |
if: inputs.repo-sonatype | |
run: ./gradlew publishAllPublicationsToSonatypeMavenRepository | |
- name: Publish Kobweb artifacts (Gradle Plugin Portal) | |
if: inputs.repo-gradle-portal | |
run: ./gradlew publishPlugins |