improve lib publishing
This commit is contained in:
parent
9fede2683f
commit
a8b5bb3adf
1 changed files with 16 additions and 2 deletions
|
@ -55,15 +55,29 @@ test:
|
||||||
junit: build/test-results/test/TEST-*.xml
|
junit: build/test-results/test/TEST-*.xml
|
||||||
|
|
||||||
|
|
||||||
publish-snapshot:
|
publish-snapshot-lib:
|
||||||
stage: publish
|
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:
|
script:
|
||||||
- ./gradlew -x assemble -x test jar
|
- ./gradlew -x assemble -x test jar
|
||||||
- ./gradlew -x assemble -x test publish
|
- ./gradlew -x assemble -x test publish
|
||||||
artifacts:
|
artifacts:
|
||||||
paths:
|
paths:
|
||||||
- build/libs/*.jar
|
- build/libs/*.jar
|
||||||
expire_in: 2 months
|
|
||||||
|
|
||||||
|
|
||||||
.fatjars:
|
.fatjars:
|
||||||
|
|
Loading…
Reference in a new issue