improve lib publishing

merge-requests/1/merge
jem 2 years ago
parent 9fede2683f
commit a8b5bb3adf

@ -55,15 +55,29 @@ test:
junit: build/test-results/test/TEST-*.xml
publish-snapshot:
publish-snapshot-lib:
stage: publish
rules:
- if: $CI_COMMIT_TAG !~ /^release-[0-9]+[.][0-9]+([.][0-9]+)?$/
script:
- ./gradlew -x assemble -x test jar
- ./gradlew -x assemble -x test publish
artifacts:
paths:
- build/libs/*.jar
publish-released-lib:
stage: publish
rules:
- if: $CI_PIPELINE_SOURCE != "push"
when: never
- if: $CI_COMMIT_TAG =~ /^release-[0-9]+[.][0-9]+([.][0-9]+)?$/
script:
- ./gradlew -x assemble -x test jar
- ./gradlew -x assemble -x test publish
artifacts:
paths:
- build/libs/*.jar
expire_in: 2 months
.fatjars:

Loading…
Cancel
Save