diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 35d6595..496a9c4 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -14,6 +14,9 @@ jobs: runs-on: ubuntu-latest steps: + - name: Updating runner + run: sudo apt-get update + - name: Setup JDK 17 uses: actions/setup-java@v4 with: @@ -42,16 +45,8 @@ jobs: } ] - - name: Display settings.xml - run: cat ~/.m2/settings.xml - - - name: Deploy - run: "mvn -DskipTests clean install deploy" - - - - - - uses: oleksiyrudenko/gha-git-credentials@latest + - name: Setup .gitconfig for version bumps + uses: oleksiyrudenko/gha-git-credentials@latest with: global: true name: 'Version Bump' @@ -59,9 +54,6 @@ jobs: actor: 'VersionBump' token: '${{ secrets.GITHUB_TOKEN }}' - - name: Preparing environment - run: sudo apt-get update - - name: Preparing settings.xml uses: s4u/maven-settings-action@v3.0.0 with: @@ -75,29 +67,20 @@ jobs: "property": { "name": "Authorization", "value": "${{ secrets.PACKAGECLOUD_TOKEN }}" - } - } - } + } } - ] - - - uses: actions/checkout@v2 - - - run: cat ~/.m2/settings.xml - - - uses: actions/setup-java@v4 - with: - distribution: 'temurin' - java-version: '17' + } + } + ] - name: Incrementing pom.xml version run: "mvn -U build-helper:parse-version versions:set -DnewVersion=\\${parsedVersion.majorVersion}.\\${parsedVersion.nextMinorVersion} versions:commit" - - name: Build + - name: Building run: "mvn -U clean install" - - name: Deploy + - name: Deploy to packagecloud.io run: "mvn -DskipTests deploy" - - name: Tag - run: "mvn scm:checkin scm:tag" \ No newline at end of file + - name: Checkin and tag to github + run: "mvn scm:checkin scm:tag"