Преглед на файлове

reverted back to tmp dir

Daniel Gibbs преди 9 години
родител
ревизия
3ef9d523ec
променени са 1 файла, в които са добавени 5 реда и са изтрити 5 реда
  1. 5 5
      lgsm/functions/command_update_linuxgsm.sh

+ 5 - 5
lgsm/functions/command_update_linuxgsm.sh

@@ -28,19 +28,19 @@ else
 fi
 fi
 
 
 echo -ne "    checking linuxgsm.sh...\c"
 echo -ne "    checking linuxgsm.sh...\c"
-tmp_script_diff=$(diff "${functionsdir}/linuxgsm.sh" <(${curlpath} -s "https://raw.githubusercontent.com/${githubuser}/${githubrepo}/${githubbranch}/linuxgsm.sh"))
+tmp_script_diff=$(diff "${tmpdir}/linuxgsm.sh" <(${curlpath} -s "https://raw.githubusercontent.com/${githubuser}/${githubrepo}/${githubbranch}/linuxgsm.sh"))
 if [ "${tmp_script_diff}" != "" ]; then
 if [ "${tmp_script_diff}" != "" ]; then
 	fn_print_update_eol_nl
 	fn_print_update_eol_nl
 	fn_script_log_info "checking linuxgsm.sh: UPDATE"
 	fn_script_log_info "checking linuxgsm.sh: UPDATE"
-	rm -f "${functionsdir}/linuxgsm.sh"
-	fn_fetch_file_github "" "linuxgsm.sh" "${functionsdir}" "nochmodx" "norun" "noforcedl" "nomd5"
+	rm -f "${tmpdir}/linuxgsm.sh"
+	fn_fetch_file_github "" "linuxgsm.sh" "${tmpdir}" "nochmodx" "norun" "noforcedl" "nomd5"
 	# Compare selfname against linuxgsm.sh in the tmp dir. Ignoring server specific vars.
 	# Compare selfname against linuxgsm.sh in the tmp dir. Ignoring server specific vars.
 else
 else
 	fn_script_log_info "checking linuxgsm.sh: OK"
 	fn_script_log_info "checking linuxgsm.sh: OK"
 	fn_print_ok_eol_nl
 	fn_print_ok_eol_nl
 fi
 fi
 echo -ne "    checking ${selfname}...\c"
 echo -ne "    checking ${selfname}...\c"
-script_diff=$(diff <(sed '/shortname/d;/servername/d;/gamename/d' "${functionsdir}/linuxgsm.sh") <(sed '/shortname/d;/servername/d;/gamename/d' "${rootdir}/${selfname}"))
+script_diff=$(diff <(sed '/shortname/d;/servername/d;/gamename/d' "${tmpdir}/linuxgsm.sh") <(sed '/shortname/d;/servername/d;/gamename/d' "${rootdir}/${selfname}"))
 if [ "${script_diff}" != "" ]; then
 if [ "${script_diff}" != "" ]; then
 	fn_print_update_eol_nl
 	fn_print_update_eol_nl
 	echo -ne "    backup ${selfname}...\c"
 	echo -ne "    backup ${selfname}...\c"
@@ -54,7 +54,7 @@ if [ "${script_diff}" != "" ]; then
 		echo -e "	Backup: ${tmpdir}/${selfname}-$(date +"%m_%d_%Y_%M").bak"
 		echo -e "	Backup: ${tmpdir}/${selfname}-$(date +"%m_%d_%Y_%M").bak"
 	fi
 	fi
 	echo -ne "    fetching ${selfname}...\c"
 	echo -ne "    fetching ${selfname}...\c"
-	cp "${functionsdir}/linuxgsm.sh" "${rootdir}/${selfname}"
+	cp "${tmpdir}/linuxgsm.sh" "${rootdir}/${selfname}"
 	sed -i "s/shortname=\"core\"/shortname=\"${shortname}\"/g" "${rootdir}/${selfname}"
 	sed -i "s/shortname=\"core\"/shortname=\"${shortname}\"/g" "${rootdir}/${selfname}"
 	sed -i "s/servername=\"core\"/servername=\"${servername}\"/g" "${rootdir}/${selfname}"
 	sed -i "s/servername=\"core\"/servername=\"${servername}\"/g" "${rootdir}/${selfname}"
 	sed -i "s/gamename=\"core\"/gamename=\"${gamename}\"/g" "${rootdir}/${selfname}"
 	sed -i "s/gamename=\"core\"/gamename=\"${gamename}\"/g" "${rootdir}/${selfname}"