Skip to content

Commit

Permalink
fix(ci): split main build an publish jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
lburgazzoli committed Jun 30, 2023
1 parent e5a8e87 commit 9454705
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions .github/workflows/build-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set Up Java
uses: actions/setup-java@v3
with:
Expand All @@ -50,16 +48,27 @@ jobs:
cache: 'gradle'
- name: Build Project
env:
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
ETCD_IMAGE: ${{ matrix.etcd }}
run: |
export TC_USER="$(id -u):$(id -g)"
echo "tc user -> $TC_USER"
./gradlew spotlessCheck
./gradlew test
publish:
runs-on: ubuntu-latest
needs: build
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set Up Java
uses: actions/setup-java@v3
with:
java-version: 11
distribution: 'temurin'
cache: 'gradle'
- name: Publish Snapshot
if: github.event_name != 'schedule'
env:
Expand Down

0 comments on commit 9454705

Please sign in to comment.