build: Use build matrix instead of branches for variants

This commit is contained in:
Geoff Bourne
2022-01-28 21:49:29 -06:00
parent 8f8acc40f5
commit 0b71383146
19 changed files with 119 additions and 85 deletions

View File

@@ -183,6 +183,7 @@ function isFamily() {
}
function isType() {
for t in "${@}"; do
# shellcheck disable=SC2153
if [[ $TYPE == "$t" ]]; then
return 0
fi
@@ -190,6 +191,17 @@ function isType() {
return 1
}
function evaluateJavaCompatibilityForForge() {
javaRelease=$(mc-image-helper java-release)
if versionLessThan 1.18 && (( javaRelease > 8 )); then
log "**********************************************************************"
log "WARNING: Some mods and modpacks may require Java 8."
log " Please use itzg/minecraft-server:java8"
log "**********************************************************************"
sleep 5
fi
}
function extract() {
src=${1?}
destDir=${2?}