Selaa lähdekoodia

Merge pull request #1231 from ChaosMTA/1230

Refreshes the package list after adding i386 architecture
Daniel Gibbs 9 vuotta sitten
vanhempi
commit
6560434968
1 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. 2 2
      lgsm/functions/check_deps.sh

+ 2 - 2
lgsm/functions/check_deps.sh

@@ -92,7 +92,7 @@ fn_found_missing_deps(){
 			sleep 1
 			sleep 1
 			echo -en "   \r"
 			echo -en "   \r"
 			if [ -n "$(command -v dpkg-query)" ]; then
 			if [ -n "$(command -v dpkg-query)" ]; then
-				cmd="sudo dpkg --add-architecture i386; sudo apt-get -y install ${array_deps_missing[@]}"
+				cmd="sudo dpkg --add-architecture i386; sudo apt-get update; sudo apt-get -y install ${array_deps_missing[@]}"
 				eval ${cmd}
 				eval ${cmd}
 			elif [ -n "$(command -v yum)" ]; then
 			elif [ -n "$(command -v yum)" ]; then
 				cmd="sudo yum -y install ${array_deps_missing[@]}"
 				cmd="sudo yum -y install ${array_deps_missing[@]}"
@@ -110,7 +110,7 @@ fn_found_missing_deps(){
 			fn_print_warning_nl "$(whoami) does not have sudo access. Manually install dependencies."
 			fn_print_warning_nl "$(whoami) does not have sudo access. Manually install dependencies."
 			fn_script_log_warn "$(whoami) does not have sudo access. Manually install dependencies."
 			fn_script_log_warn "$(whoami) does not have sudo access. Manually install dependencies."
 			if [ -n "$(command -v dpkg-query)" ]; then
 			if [ -n "$(command -v dpkg-query)" ]; then
-				echo "	sudo dpkg --add-architecture i386; sudo apt-get install ${array_deps_missing[@]}"
+				echo "	sudo dpkg --add-architecture i386; sudo apt-get update; sudo apt-get install ${array_deps_missing[@]}"
 			elif [ -n "$(command -v yum)" ]; then
 			elif [ -n "$(command -v yum)" ]; then
 				echo "	sudo yum install ${array_deps_missing[@]}"
 				echo "	sudo yum install ${array_deps_missing[@]}"
 			fi
 			fi