From c9ffcfb1e8069ca10f9bde50c8f0508812dff0b1 Mon Sep 17 00:00:00 2001 From: James Seibel Date: Sat, 22 Jan 2022 20:50:16 -0600 Subject: [PATCH] Add jar merging to the pipeline --- .gitlab-ci.yml | 29 +++++++++++++++++++++++++++-- 1 file changed, 27 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 76c5e84d1..ff4cbdf66 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,6 +1,11 @@ # use Eclipse's JDK image: gradle:eclipse-temurin +# all stages need to be defined here +stages: + - build + - merge + variables: # Disable the Gradle daemon for Continuous Integration servers as correctness # is usually a priority over speed in CI environments. Using a fresh @@ -36,11 +41,31 @@ build: - fabric/build/libs - forge/build/libs reports: - # To ensure we've access to this file in the next stage + # To ensure we've access to these files in the next stage dotenv: generate_jars.env +# second stage +merge: + stage: merge + script: ./gradlew merge + # build using Java 17 + image: eclipse-temurin:17 + cache: + key: "$CI_COMMIT_REF_NAME" + policy: push + paths: + - fabric/build/libs + - forge/build/libs + artifacts: + paths: + # relative to the root directory + - Merged + reports: + # To ensure we've access to this file in the next stage + dotenv: merged_jar.env -## second stage + +## third stage #deploy: # stage: deploy # image: registry.gitlab.com/gitlab-org/release-cli:latest