diff --git a/.github/workflows/ci.yaml b/.github/workflows/release.yaml similarity index 65% rename from .github/workflows/ci.yaml rename to .github/workflows/release.yaml index 27fce37..fbfe0f8 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/release.yaml @@ -1,37 +1,13 @@ -name: CI +name: release on: + workflow_dispatch: push: branches: [ main ] - pull_request: - branches: [ main ] - -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true jobs: - test: - name: Run Tests - if: github.event_name == 'pull_request' - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v4 - - - name: Set up JDK 21 - uses: actions/setup-java@v4 - with: - distribution: 'temurin' - java-version: '21' - cache: 'gradle' - - - name: Test with Gradle - run: ./gradlew check - build-and-publish: name: Build and Publish - if: github.event_name == 'push' && github.ref == 'refs/heads/main' runs-on: ubuntu-latest permissions: contents: read diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml new file mode 100644 index 0000000..6d88254 --- /dev/null +++ b/.github/workflows/test.yaml @@ -0,0 +1,23 @@ +name: test + +on: [push] + +jobs: + test: + name: Run Tests + runs-on: ubuntu-latest + permissions: + contents: read + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up JDK 21 + uses: actions/setup-java@v4 + with: + distribution: 'temurin' + java-version: '21' + cache: 'gradle' + + - name: Test with Gradle + run: ./gradlew check