Skip to content

Commit

Permalink
Generate pom file (#83)
Browse files Browse the repository at this point in the history
The `build-java` job also generates and archives the pom file.
 
# Checklist

The following aspects have been respected by the author of this pull
request, confirmed by both pull request assignee **and** reviewer:

* Changelog update (necessity checked and entry added or not added
respectively)
  * [x] Pull Request Assignee
  * [x] Reviewer
* README update (necessity checked and entry added or not added
respectively)
  * [x] Pull Request Assignee
  * [x] Reviewer
  • Loading branch information
belagertem authored Jun 14, 2024
1 parent 6a56dae commit d56c313
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions .github/workflows/build-java.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,20 @@ jobs:
gradle-version: ${{ env.GRADLE_VERSION }}
- name: Execute build
working-directory: ./java
run: ./gradlew jar
- name: Archive built jars
run: ./gradlew jar generatePomFileForMavenPublication
- name: Rename pom file for release
if: startsWith(github.ref, 'refs/tags/v')
working-directory: ./java/build/publications/maven
run: mv pom-default.xml ./../../libs/t2iapi-${{ env.BASE_PACKAGE_VERSION }}.pom
- name: Rename pom file for snapshot
if: ${{ !startsWith(github.ref, 'refs/tags/v') }}
working-directory: ./java/build/publications/maven
run: mv pom-default.xml ./../../libs/t2iapi-${{ env.BASE_PACKAGE_VERSION }}.${{ github.run_number }}-SNAPSHOT.pom
- name: Archive built jars and pom
uses: actions/upload-artifact@v4
with:
name: target_jars
path: java/build/libs/*.jar
path: java/build/libs
run-tests-java17:
runs-on: ubuntu-latest
needs: build-java
Expand Down

0 comments on commit d56c313

Please sign in to comment.