From 9996144ee24b5c97fdcda74e5c0f7cc6c91785af Mon Sep 17 00:00:00 2001 From: William278 Date: Wed, 1 Mar 2023 12:48:49 +0000 Subject: [PATCH] Add modritnh CI via workflow --- .github/workflows/java_ci.yml | 35 ++++++++++++++++++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) diff --git a/.github/workflows/java_ci.yml b/.github/workflows/java_ci.yml index c150a33..83a2009 100644 --- a/.github/workflows/java_ci.yml +++ b/.github/workflows/java_ci.yml @@ -21,4 +21,37 @@ jobs: - name: Build with Gradle uses: gradle/gradle-build-action@67421db6bd0bf253fb4bd25b31ebb98943c375e1 with: - arguments: build \ No newline at end of file + arguments: build + - name: Query Version + run: | + echo "::set-output name=VERSION_NAME::$(${{github.workspace}}/gradlew properties --no-daemon --console=plain -q | grep "^version:" | awk '{printf $2}')" + id: fetch-version + - name: Get Version + run: | + echo "version_name=${{steps.fetch-version.outputs.VERSION_NAME}}" >> $GITHUB_ENV + - name: Upload to Modrinth + uses: Kir-Antipov/mc-publish@v3.2 + with: + modrinth-id: Q10irTG0 + modrinth-featured: false + modrinth-token: ${{ secrets.MODRINTH_TOKEN }} + files-primary: build/libs/Velocitab-*-all.jar + name: Velocitab v${{ env.version_name }} + version: ${{ env.version_name }} + version-type: alpha + changelog: ${{ github.event.head_commit.message }} + loaders: | + velocity + dependencies: | + protocolize | depends | 2.2.5 + luckperms | suggests | * + game-versions: | + 1.19 + 1.19.2 + 1.19.3 + java: 16 + - name: Upload GitHub Artifact + uses: actions/upload-artifact@v2 + with: + name: Velocitab Plugin + path: build/libs/Velocitab-*-all.jar \ No newline at end of file