Browse Source

Update update_mc.sh (#4563)

If the executable variable is modified, fn_update_dl does not update minecraft_server.jar and which is used in fn_update_localbuild.

In addition this creates a problem if a alternative executable is used to launch minecraft by overwriting it.

Co-authored-by: Daniel Gibbs <[email protected]>
pull/4571/head
BertBrenner 11 months ago
committed by GitHub
parent
commit
1c596972ff
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 2
      lgsm/modules/update_mc.sh

2
lgsm/modules/update_mc.sh

@ -10,7 +10,7 @@ moduleselfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
fn_update_dl() { fn_update_dl() {
# Download and extract files to serverfiles. # Download and extract files to serverfiles.
fn_fetch_file "${remotebuildurl}" "" "" "" "${tmpdir}" "${remotebuildfilename}" "chmodx" "norun" "noforce" "nohash" fn_fetch_file "${remotebuildurl}" "" "" "" "${tmpdir}" "${remotebuildfilename}" "chmodx" "norun" "noforce" "nohash"
cp -f "${tmpdir}/${remotebuildfilename}" "${serverfiles}/${executable#./}" cp -f "${tmpdir}/${remotebuildfilename}" "${serverfiles}/minecraft_server.jar"
fn_clear_tmp fn_clear_tmp
} }

Loading…
Cancel
Save