Upgrade now handled with dialog.
This commit is contained in:
parent
ef7dc8591a
commit
0fea6213de
@ -86,10 +86,8 @@ update() {
|
|||||||
if [[ "$(wget --quiet -O - https://stormgames.wolfe.casa/downloads/${downloadFile} | sha256sum | cut -d ' ' -f1)" == "$(sha256sum "${filePath}" | cut -d ' ' -f1)" ]]; then
|
if [[ "$(wget --quiet -O - https://stormgames.wolfe.casa/downloads/${downloadFile} | sha256sum | cut -d ' ' -f1)" == "$(sha256sum "${filePath}" | cut -d ' ' -f1)" ]]; then
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
echo "There is a new version of ${0##*/} available."
|
dialog --backtitle "Audiogame Manager" --yesno "There is a new version of ${0##*/} available.\nDo you want to update now?" -1 -1
|
||||||
echo "Do you want to update now?"
|
if [[ ${continue} -eq 0 ]]; then
|
||||||
read -r continue
|
|
||||||
if [[ "${continue,,}" =~ ^y|ye|yes$ ]]; then
|
|
||||||
if [[ -w "$0" ]]; then
|
if [[ -w "$0" ]]; then
|
||||||
wget --quiet -O "${filePath}" "https://stormgames.wolfe.casa/downloads/${downloadFile}"
|
wget --quiet -O "${filePath}" "https://stormgames.wolfe.casa/downloads/${downloadFile}"
|
||||||
chmod +x "$0"
|
chmod +x "$0"
|
||||||
|
Loading…
Reference in New Issue
Block a user