1
0
mirror of https://gitlab.com/JKANetwork/JKArch.git synced 2026-02-14 09:11:31 +01:00
Files
JKArch/archinstall/downloadinstall.sh
kprkpr c3e0ee0981 gksu
2016-06-08 20:58:24 +02:00

29 lines
1.4 KiB
Bash
Executable File

#!/bin/bash
opt=`dialog --stdout --nocancel --backtitle "Instalacion de JKArch / JKArch installation" --title "Bienvenido a JKArch / Welcome" --menu "Para poder comenzar la instalacion, se necesita una conexion a internet. / We need an internet conection to start" 0 70 5 1 "Estoy por cable (Ethernet) /I'm using cable" 2 "Wi-Fi" 3 "Configuracion compleja (Ir a la terminal) / Other (Terminal)"`
if [[ $opt -eq 2 ]];then
wifi-menu
elif [[ $opt -eq 3 ]];then
clear
echo "Te sacamos a la terminal, configure internet, asegurese de que funcione y después escriba exit para continuar"
echo "You will go to the bash terminal, you can configure network, and then write exit"
bash
fi
clear
echo "Vamos a comprobar que tienes conexión a internet"
echo "Testing network conection"
ping 8.8.8.8 -c3
if [[ $? != 0 ]];then
clear
dialog --title "Conexión / Network " --msgbox "Error en la conexión \nse reiniciará la instalación \n\n Network error. Restarting the install.." 15 60
exec ./downloadinstall.sh
fi
wget -nv https://gitlab.com/JKANetwork/JKArch/raw/master/archinstall/selectlang.sh -O selectlang.sh
if [ $(cat selectlang.sh | grep "^<\!DOCTYPE html>") == "<\!DOCTYPE html>" ];then
clear
dialog --title "Descarga incorrecta / Corrupted download" --msgbox "La descarga del instalador ha fallado \nse reiniciará la instalación \n\n Download failed. Restarting install.." 15 60
exec ./downloadinstall.sh
fi
chmod +x selectlang.sh
exec ./selectlang.sh