diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml index 59059f4..48f783c 100644 --- a/.github/workflows/gradle.yml +++ b/.github/workflows/gradle.yml @@ -25,7 +25,7 @@ jobs: uses: gradle/gradle-build-action@937999e9cc2425eddc7fd62d1053baf041147db7 with: arguments: :free:shadowJar - - name: Upload a Build Artifact + - name: Upload plugin jar artifact uses: actions/upload-artifact@v2.3.1 with: # Artifact name @@ -33,4 +33,28 @@ jobs: # A file, directory or wildcard pattern that describes what to upload path: free/build/libs/ajQueue*.jar # The desired behavior if no files are found using the provided path. - if-no-files-found: error \ No newline at end of file + if-no-files-found: error + - name: Upload build files artifact + uses: actions/upload-artifact@v2.3.1 + with: + # Artifact name + name: build-files + # A file, directory or wildcard pattern that describes what to upload + path: '*/build/*' + # The desired behavior if no files are found using the provided path. + if-no-files-found: error + retention-days: 2 + deploy: + runs-on: ubuntu-latest + environment: maven-repo-deploy + needs: build + if: github.ref == 'refs/heads/master' + steps: + - uses: actions/checkout@v2 + - uses: actions/download-artifact@v2 + with: + name: build-files + - name: Deploy with Gradle + uses: gradle/gradle-build-action@937999e9cc2425eddc7fd62d1053baf041147db7 + with: + arguments: :api:publish :common:publish \ No newline at end of file