mirror of
https://gitlab.kit.edu/uskyk/typicalc.git
synced 2024-11-09 10:50:42 +00:00
CI: build-test-package pipeline
This commit is contained in:
parent
74c21773d4
commit
70ce558cd0
@ -1,9 +1,22 @@
|
|||||||
|
stages:
|
||||||
|
- Build
|
||||||
|
- Test
|
||||||
|
- Package
|
||||||
|
|
||||||
variables:
|
variables:
|
||||||
NIX_PATH: "nixpkgs=channel:nixos-21.05"
|
NIX_PATH: "nixpkgs=channel:nixos-21.05"
|
||||||
|
|
||||||
build:
|
build:
|
||||||
|
stage: Build
|
||||||
script:
|
script:
|
||||||
- nix-shell --pure --run "file src/main/resources/language/translation_de.properties | rg UTF-8"
|
- nix-shell --pure --run "file src/main/resources/language/translation_de.properties | rg UTF-8"
|
||||||
|
- nix-shell --pure --run "mvn --no-transfer-progress -Dmaven.repo.local=/tmp/m2/repository -Duser.home=/tmp compile"
|
||||||
|
|
||||||
|
test:
|
||||||
|
stage: Test
|
||||||
|
dependencies:
|
||||||
|
- build
|
||||||
|
script:
|
||||||
- nix-shell --pure --run "mvn --no-transfer-progress -Dmaven.repo.local=/tmp/m2/repository -Duser.home=/tmp checkstyle:check jacoco:prepare-agent test jacoco:report"
|
- nix-shell --pure --run "mvn --no-transfer-progress -Dmaven.repo.local=/tmp/m2/repository -Duser.home=/tmp checkstyle:check jacoco:prepare-agent test jacoco:report"
|
||||||
- nix-shell --pure --run "python3 ./cover2cover.py target/site/jacoco/jacoco.xml src/main/java > target/site/cobertura.xml"
|
- nix-shell --pure --run "python3 ./cover2cover.py target/site/jacoco/jacoco.xml src/main/java > target/site/cobertura.xml"
|
||||||
- nix-shell --pure --run "python3 ./source2filename.py target/site/cobertura.xml"
|
- nix-shell --pure --run "python3 ./source2filename.py target/site/cobertura.xml"
|
||||||
@ -11,3 +24,13 @@ build:
|
|||||||
artifacts:
|
artifacts:
|
||||||
reports:
|
reports:
|
||||||
cobertura: target/site/cobertura.xml
|
cobertura: target/site/cobertura.xml
|
||||||
|
|
||||||
|
package:
|
||||||
|
stage: Package
|
||||||
|
dependencies:
|
||||||
|
- test
|
||||||
|
script:
|
||||||
|
- nix-shell --pure --run "mvn --no-transfer-progress -Dmaven.repo.local=/tmp/m2/repository -Duser.home=/tmp clean package -Pproduction"
|
||||||
|
artifacts:
|
||||||
|
paths:
|
||||||
|
- target/typicalc-1.0-SNAPSHOT.jar
|
Loading…
Reference in New Issue
Block a user