diff --git a/scripts/luckfox-install.sh b/scripts/luckfox-install.sh index cef1543..7f17d9d 100644 --- a/scripts/luckfox-install.sh +++ b/scripts/luckfox-install.sh @@ -1,4 +1,8 @@ -echo "*** $(date "+%H:%M:%S %Z"): Starting Femtofox install script. \e[1;31mNETWORK CONNECTIVITY REQUIRED! ***\e[0m\n" +echo "*** Starting Femtofox install script. \e[1;31mNETWORK CONNECTIVITY REQUIRED! ***\e[0m\n" + +sudo timedatectl set-timezone UTC #Set timezone to UTC. +date -d "$(wget --method=HEAD -qSO- --max-redirect=0 google.com 2>&1 | grep Date: | cut -d' ' -f4-10)" #Set time/date. +echo "*** $(date "+%H:%M:%S %Z") Changed timezone to UTC and got network time ***\e[0m\n" read -p "Enter wifi SSID: " SSID echo -n "Enter wifi password: " @@ -16,10 +20,6 @@ else echo "*** $(date "+%H:%M:%S %Z"): tmpfs already enlarged, skipping ***\e[0m\n" fi -sudo timedatectl set-timezone UTC #Set timezone to UTC. -date -d "$(wget --method=HEAD -qSO- --max-redirect=0 google.com 2>&1 | grep Date: | cut -d' ' -f4-10)" #Set time/date. -echo "*** $(date "+%H:%M:%S %Z") Changed timezone to UTC and got network time ***\e[0m\n" - #update system and install dependencies echo "*** $(date "+%H:%M:%S %Z"): Updating and upgrading Ubuntu... ***\e[0m\n" sudo DEBIAN_FRONTEND=noninteractive apt-get -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" -y update && sudo DEBIAN_FRONTEND=noninteractive apt-get -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" -y upgrade