From 58a9b4cf6f3bb10e5f38cf931a6e0204c7752585 Mon Sep 17 00:00:00 2001 From: TheMCLoveMan Date: Tue, 13 Jun 2023 15:24:12 +0200 Subject: [PATCH] update CI and Publish workflows --- .github/workflows/java_ci.yml | 24 ++---------------------- .github/workflows/publish.yml | 33 +++++++-------------------------- 2 files changed, 9 insertions(+), 48 deletions(-) diff --git a/.github/workflows/java_ci.yml b/.github/workflows/java_ci.yml index 9fb3914..e82a0c9 100644 --- a/.github/workflows/java_ci.yml +++ b/.github/workflows/java_ci.yml @@ -8,30 +8,10 @@ on: - '.github/**' - '**.md' - '**.txt' - pull_request: - tags-ignore: - - '**' - paths-ignore: - - '.github/**' - - '**.md' - - '**.txt' permissions: contents: read jobs: - build: - runs-on: ubuntu-latest - - steps: - - name: Checkout - uses: actions/checkout@v3 - - name: Set up JDK 17 - uses: actions/setup-java@v3 - with: - java-version: '17' - distribution: 'microsoft' - - name: Set up Gradle - uses: gradle/gradle-build-action@v2 - - name: Build with Gradle - run: chmod +x ./gradlew && ./gradlew build + ci: + uses: TheMCBrothers/.github/.github/workflows/mod_ci.yml@main \ No newline at end of file diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index aef5e2b..499b268 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -9,29 +9,10 @@ permissions: contents: read jobs: - build: - runs-on: ubuntu-latest - env: - cf_key: ${{ secrets.CURSEFORGE_TOKEN }} - modrinth_token: ${{ secrets.MODRINTH_TOKEN }} - nexus_uname: ${{ secrets.PUBLISH_USER }} - nexus_pwd: ${{ secrets.PUBLISH_PASSWORD }} - - steps: - - name: Checkout - uses: actions/checkout@v3 - - name: Set up JDK 17 - uses: actions/setup-java@v3 - with: - java-version: '17' - distribution: 'microsoft' - - name: Set up Gradle - uses: gradle/gradle-build-action@v2 - - name: Build with Gradle - run: chmod +x ./gradlew && ./gradlew build - - name: Publish to Nexus - run: ./gradlew publish - - name: Publish to Modrinth - run: ./gradlew modrinth - - name: Publish to CurseForge - run: ./gradlew curseforge + publish: + uses: TheMCBrothers/.github/.github/workflows/mod_publish.yml@main + secrets: + CURSEFORGE_TOKEN: ${{ secrets.CURSEFORGE_TOKEN }} + MODRINTH_TOKEN: ${{ secrets.MODRINTH_TOKEN }} + PUBLISH_USER: ${{ secrets.PUBLISH_USER }} + PUBLISH_PASSWORD: ${{ secrets.PUBLISH_PASSWORD }} \ No newline at end of file