diff --git a/.github/workflows/java_ci.yml b/.github/workflows/java_ci.yml index b5b8d5b2b2..f97389ec72 100644 --- a/.github/workflows/java_ci.yml +++ b/.github/workflows/java_ci.yml @@ -36,13 +36,6 @@ jobs: - name: Build and test with Maven run: mvn clean install --batch-mode --no-transfer-progress --file pom.xml - - - name: Deploy snapshot - env: - ARTF_USER: ${{ secrets.ARTF_USER }} - ARTF_PASS: ${{ secrets.ARTF_PASS }} - run: printenv -# run: mvn install javadoc:jar source:jar deploy --batch-mode --no-transfer-progress --file pom.xml -s $GITHUB_WORKSPACE/settings.xml # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL diff --git a/.github/workflows/publish_snapshot.yaml b/.github/workflows/publish_snapshot.yaml new file mode 100644 index 0000000000..04e4b7eba5 --- /dev/null +++ b/.github/workflows/publish_snapshot.yaml @@ -0,0 +1,39 @@ +# this workflow will deploy SNAPSHOT on pushes to develop branch + +name: Java CI with Maven + +on: + push: + branches: [ develop ] + +jobs: + build: + name: Deploy SNAPSHOT + runs-on: ubuntu-latest + permissions: + actions: read + contents: read + security-events: write + + strategy: + fail-fast: false + matrix: + language: [ 'java' ] + + steps: + - name: Checkout the repository + uses: actions/checkout@v3 + + - name: Set up JDK 17 + uses: actions/setup-java@v3 + with: + java-version: '17' + distribution: 'temurin' + cache: maven + + - name: Build and test with Maven + env: + ARTF_USER: ${{ secrets.ARTF_USER }} + ARTF_PASS: ${{ secrets.ARTF_PASS }} + run: mvn clean install deploy --batch-mode --no-transfer-progress --file pom.xml -s $GITHUB_WORKSPACE/settings.xml +