Browse Source

fix(mtaserver): fix broken download url

fix mta download url
Daniel Gibbs 7 năm trước cách đây
mục cha
commit
daa34af16b
2 tập tin đã thay đổi với 8 bổ sung7 xóa
  1. 4 3
      .travis.yml
  2. 4 4
      lgsm/functions/update_mta.sh

+ 4 - 3
.travis.yml

@@ -1,8 +1,9 @@
-language: bash node_js
+
+language: node_js
 dist: xenial
-sudo: required
 node_js:
   - 10
+
 before_script:
     - curl -L "https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/shunit2/shunit2-2.1.6.tgz" | tar zx
 install:
@@ -42,4 +43,4 @@ jobs:
     - # stage name not required
       script: bash tests/tests_ts3server.sh
     - # stage name not required
-      script: bash tests/tests_shellcheck.sh
+      script: bash tests/tests_shellcheck.sh

+ 4 - 4
lgsm/functions/update_mta.sh

@@ -9,11 +9,11 @@ local commandaction="Update"
 local function_selfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
 
 fn_update_mta_dl(){
-	fn_fetch_file "http://linux.mtasa.com/dl/${numversion}/multitheftauto_linux_x64-${fullversion}.tar.gz" "${tmpdir}" "multitheftauto_linux_x64-${fullversion}.tar.gz"
-	mkdir "${tmpdir}/multitheftauto_linux_x64-${fullversion}"
-	fn_dl_extract "${tmpdir}" "multitheftauto_linux_x64-${fullversion}.tar.gz" "${tmpdir}/multitheftauto_linux_x64-${fullversion}"
+	fn_fetch_file "http://linux.mtasa.com/dl/multitheftauto_linux_x64.tar.gz" "${tmpdir}" "multitheftauto_linux_x64.tar.gz"
+	mkdir "${tmpdir}/multitheftauto_linux_x64"
+	fn_dl_extract "${tmpdir}" "multitheftauto_linux_x64.tar.gz" "${tmpdir}/multitheftauto_linux_x64"
 	echo -e "copying to ${serverfiles}...\c"
-	cp -R "${tmpdir}/multitheftauto_linux_x64-${fullversion}/multitheftauto_linux_x64-${fullversion}/"* "${serverfiles}"
+	cp -R "${tmpdir}/multitheftauto_linux_x64/multitheftauto_linux_x64/"* "${serverfiles}"
 	local exitcode=$?
 	if [ "${exitcode}" == "0" ]; then
 		fn_print_ok_eol_nl