Skip to content

Build task should actually build the application, not publish #1

Build task should actually build the application, not publish

Build task should actually build the application, not publish #1

Workflow file for this run

# Based off https://github.com/MinecraftForge/SharedActions/blob/main/.github/workflows/gradle.yml
name: Gradle Building CI
on:
workflow_call:
inputs:
java:
description: "The version of Java to use to run Gradle" # Note: Gradle's Java toolchains feature is used for compiling, which is separate from this
required: false
type: string
default: "21"
gradle_tasks:
description: "The Gradle task(s) to run for building"
required: false
type: string
default: "assemble"
secrets:
GRADLE_ENCRYPTION_KEY:
description: The AES key to enable Gradle cache encryption
required: false
permissions:
contents: read
jobs:
compute-version:
name: Compute version
runs-on: ubuntu-latest
steps:
- uses: ldtteam/operapublicacreator/.github/workflows/gradle.version.yaml@${{ github.workflow_sha }}
with:
suffix: ${{ github.event_name == 'pull_request' && format('pr-{0}', github.event.number) || format('branch-{0}', steps.computeBranchSuffix.outputs.branch_suffix) }}
build:
runs-on: ubuntu-latest
steps:
- id: checkout
name: "📦 Checkout"
uses: actions/checkout@v4
- id: setupGradle
name: "🔧 Setup Gradle"
uses: gradle/actions/setup-gradle@v4
with:
gradle-version: wrapper
cache-encryption-key: ${{ secrets.GRADLE_ENCRYPTION_KEY }}
- id: build
name: "🏗️ Build"
run: ./gradlew --build-cache ${{ inputs.gradle_tasks }}
env:
Version: "${{ needs.compute-version.outputs.version }}"