mirror of
https://github.com/RetroDECK/RetroDECK.git
synced 2024-11-22 14:05:39 +00:00
Fix typo & remove progress dlg from network check
This commit is contained in:
parent
68e9e77380
commit
c55e9e5c63
|
@ -4,23 +4,15 @@ check_network_connectivity() {
|
||||||
# This function will do a basic check for network availability and return "true" if it is working.
|
# This function will do a basic check for network availability and return "true" if it is working.
|
||||||
# USAGE: if [[ $(check_network_connectivity) == "true" ]]; then
|
# USAGE: if [[ $(check_network_connectivity) == "true" ]]; then
|
||||||
|
|
||||||
(
|
|
||||||
local response=
|
|
||||||
|
|
||||||
if [[ ! -z $(wget --spider -t 1 $remote_network_target_1 | grep "HTTP response 200") ]]; then
|
if [[ ! -z $(wget --spider -t 1 $remote_network_target_1 | grep "HTTP response 200") ]]; then
|
||||||
local network_connnected="true"
|
local network_connected="true"
|
||||||
elif [[ ! -z $(wget --spider -t 1 $remote_network_target_2 | grep "HTTP response 200") ]]; then
|
elif [[ ! -z $(wget --spider -t 1 $remote_network_target_2 | grep "HTTP response 200") ]]; then
|
||||||
local network_connnected="true"
|
local network_connected="true"
|
||||||
elif [[ ! -z $(wget --spider -t 1 $remote_network_target_3 | grep "HTTP response 200") ]]; then
|
elif [[ ! -z $(wget --spider -t 1 $remote_network_target_3 | grep "HTTP response 200") ]]; then
|
||||||
local network_connnected="true"
|
local network_connected="true"
|
||||||
else
|
else
|
||||||
local network_connnected="false"
|
local network_connected="false"
|
||||||
fi
|
fi
|
||||||
) |
|
|
||||||
zenity --icon-name=net.retrodeck.retrodeck --progress --no-cancel --pulsate --auto-close \
|
|
||||||
--window-icon="/app/share/icons/hicolor/scalable/apps/net.retrodeck.retrodeck.svg" \
|
|
||||||
--title "RetroDECK Network Check" \
|
|
||||||
--text="Verifying network connectivity..."
|
|
||||||
|
|
||||||
echo "$network_connected"
|
echo "$network_connected"
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue