File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 88 name : Maven-Java
99 runs-on : ubuntu-22.04
1010 timeout-minutes : 10
11+ if : github.event_name == 'pull_request' && github.event.action != 'closed'
1112 steps :
1213 - uses : actions/checkout@v4
1314 - uses : aboutbits/github-actions-java/setup@v3
2526 GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2627
2728 snapshot :
28- name : Publish snapshot
29+ name : Publish Snapshot
2930 runs-on : ubuntu-22.04
3031 timeout-minutes : 10
3132 needs : test
5354 timeout-minutes : 10
5455 if : github.event_name == 'pull_request' && github.event.action == 'closed'
5556 steps :
56- - name : Authenticate with GitHub Packages
57- run : echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $GITHUB_USER_NAME --password-stdin
5857 - name : Remove snapshot version from repository
58+ uses : actions/delete-package-versions@v5
59+ with :
60+ package-type : ' maven'
61+ package-name : ' it.aboutbits.spring-boot-toolbox'
62+ package-version-ids : ' PR-${{ github.event.pull_request.number }}'
63+ token : ${{ secrets.GITHUB_PAT }}
5964 run : |
6065 curl -X DELETE -u ${{ github.actor }}:${{ secrets.GITHUB_TOKEN }} \
61- https://maven.pkg.github.com/OWNER/REPOSITORY/com/example/myartifact /PR-${{ github.event.pull_request.number }}/
66+ https://maven.pkg.github.com/aboutbits/spring-boot-toolbox /PR-${{ github.event.pull_request.number }}/
You can’t perform that action at this time.
0 commit comments