2022-04-10 18:46:28 +02:00
|
|
|
dist: focal
|
2022-04-10 19:57:53 +02:00
|
|
|
|
2018-11-08 20:05:38 +01:00
|
|
|
language: java
|
2022-04-10 19:57:53 +02:00
|
|
|
|
|
|
|
matrix:
|
|
|
|
include:
|
|
|
|
- env:
|
2024-04-28 21:04:48 +02:00
|
|
|
- JDK_VERSION=11
|
2022-04-10 19:57:53 +02:00
|
|
|
|
2021-06-26 19:13:00 +02:00
|
|
|
before_install:
|
2022-04-10 19:57:53 +02:00
|
|
|
- "[[ -d $HOME/.sdkman/ ]] && [[ -d $HOME/.sdkman/bin/ ]] || rm -rf $HOME/.sdkman/"
|
2022-04-10 18:46:28 +02:00
|
|
|
- curl -s "https://get.sdkman.io" | bash
|
2022-04-10 19:57:53 +02:00
|
|
|
- mkdir -p "$HOME/.sdkman/etc/"
|
|
|
|
- echo sdkman_auto_answer=true > "$HOME/.sdkman/etc/config"
|
|
|
|
- echo sdkman_auto_selfupdate=true >> "$HOME/.sdkman/etc/config"
|
2022-04-10 18:46:28 +02:00
|
|
|
- source "$HOME/.sdkman/bin/sdkman-init.sh"
|
2022-04-10 19:57:53 +02:00
|
|
|
|
|
|
|
install:
|
|
|
|
- sdk install java $(sdk list java | grep -o "$JDK_VERSION\.[0-9]*\.[0-9]*\-open" | head -1)
|
2022-04-10 18:46:28 +02:00
|
|
|
- sdk install maven
|
2022-04-10 19:57:53 +02:00
|
|
|
- export JAVA_HOME="$HOME/.sdkman/candidates/java/current"
|
|
|
|
- export PATH=${JAVA_HOME}/bin:${PATH}
|
|
|
|
- export MAVEN_HOME="$HOME/.sdkman/candidates/maven/current"
|
|
|
|
- export M2_HOME="$MAVEN_HOME"
|
|
|
|
- export PATH=${M2_HOME}/bin:${PATH}
|
|
|
|
- env
|
|
|
|
- mvn -v
|
|
|
|
|
2018-11-08 20:05:38 +01:00
|
|
|
cache:
|
|
|
|
directories:
|
2022-04-10 19:57:53 +02:00
|
|
|
- $HOME/.m2/repository
|