From 4be4fc4808a90f6cd44f8875a11eaf01fd3d3130 Mon Sep 17 00:00:00 2001 From: Tyler Heucke <7104923+heucke@users.noreply.github.com> Date: Fri, 30 Apr 2021 09:05:56 -0700 Subject: [PATCH] Corrected locating of CF modpack server jar when not using server script (#852) --- start-deployCF | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/start-deployCF b/start-deployCF index 52e6b6eb..1b41ace6 100644 --- a/start-deployCF +++ b/start-deployCF @@ -60,8 +60,8 @@ if ! isTrue ${USE_MODPACK_START_SCRIPT:-true}; then mkdir -p ${FTB_BASE_DIR} unzip -o "${FTB_SERVER_MOD}" -d ${FTB_BASE_DIR} | awk '{printf "."} END {print ""}' - SERVER=$(find ${FTB_BASE_DIR} -type f -not -name "forge*installer.jar" -name "forge*.jar") - if [[ -z "$SERVER" ]]; then + serverJar=$(find ${FTB_BASE_DIR} -type f -path "*/libraries/*" -prune -o -name "forge*.jar" -not -name "forge*installer.jar" -print) + if [[ -z "$serverJar" ]]; then if [ -f "${FTB_BASE_DIR}/settings.cfg" ]; then loadForgeVars "${FTB_BASE_DIR}/settings.cfg" @@ -89,15 +89,14 @@ if ! isTrue ${USE_MODPACK_START_SCRIPT:-true}; then fi echo "${FTB_SERVER_MOD}" > $installMarker - SERVER=$(find ${FTB_BASE_DIR} -type f -not -name "forge*installer.jar" -name "forge*.jar") fi + export SERVER=$(find ${FTB_BASE_DIR} -type f -path "*/libraries/*" -prune -o -name "forge*.jar" -not -name "forge*installer.jar" -print) if [[ -z "${SERVER}" || ! -f "${SERVER}" ]]; then log "ERROR unable to locate installed forge server jar" isDebugging && find ${FTB_BASE_DIR} -name "forge*.jar" exit 2 fi - export SERVER export FTB_DIR=$(dirname "${SERVER}")