Added yad dialogues if in GUI session, retains the dialog interface if in console.
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
#!/bin/bash
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# âe contents of this file are subject to the Common Public Attribution
|
||||
# License Version 1.0 (the âcenseâ you may not use this file except in
|
||||
@ -37,6 +37,10 @@
|
||||
# Works which are defined in the CPAL as a work which combines Covered Code
|
||||
# or portions thereof with code not governed by the terms of the CPAL.
|
||||
|
||||
|
||||
# Source dialog interface wrapper
|
||||
source "${0%/*}/../.includes/dialog-interface.sh"
|
||||
|
||||
for i in dialog unix2dos; do
|
||||
if ! command -v $i &> /dev/null ; then
|
||||
echo "Please install dialog and dos2unix before using this script."
|
||||
@ -55,12 +59,7 @@ for i in "${gameList[@]}" ; do
|
||||
done
|
||||
|
||||
unset gameList
|
||||
gameList="$(dialog --clear \
|
||||
--no-tags \
|
||||
--ok-label "Add Games" \
|
||||
--separate-output \
|
||||
--backtitle "Select games to add to the $1 list." \
|
||||
--checklist "Press space to check or uncheck a selected game." 0 0 0 "${menuList[@]}" --stdout)"
|
||||
gameList="$(agm_checklist "Crazy Party Game Builder" "Crazy Party Game Builder" "Press space to check or uncheck a selected game." "${menuList[@]}")"
|
||||
|
||||
if [[ -z "${gameList}" ]]; then
|
||||
exit 0
|
||||
@ -70,5 +69,5 @@ mkdir -p "$HOME/.local/wine/crazy-party/drive_c/Program Files/Crazy-Party-beta73
|
||||
echo "$gameList" >> "$HOME/.local/wine/crazy-party/drive_c/Program Files/Crazy-Party-beta73/game/${1}.txt"
|
||||
sort -uno "$HOME/.local/wine/crazy-party/drive_c/Program Files/Crazy-Party-beta73/game/${1}.txt" "$HOME/.local/wine/crazy-party/drive_c/Program Files/Crazy-Party-beta73/game/${1}.txt"
|
||||
eunix2dos "$HOME/.local/wine/crazy-party/drive_c/Program Files/Crazy-Party-beta73/game/${1}.txt"
|
||||
dialog --infobox "Game list \"$1\" updated." 10 80
|
||||
agm_infobox "Crazy Party Game Builder" "Crazy Party Game Builder" "Game list \"$1\" updated."
|
||||
exit 0
|
||||
|
@ -37,6 +37,10 @@
|
||||
# Works which are defined in the CPAL as a work which combines Covered Code
|
||||
# or portions thereof with code not governed by the terms of the CPAL.
|
||||
|
||||
|
||||
# Source dialog interface wrapper
|
||||
source "${0%/*}/../.includes/dialog-interface.sh"
|
||||
|
||||
newVersion=82
|
||||
|
||||
WINEPREFIX="${XDG_DATA_HOME:-$HOME/.local}/wine/crazy-party"
|
||||
@ -68,6 +72,6 @@ find "${WINEPREFIX}" -type f -name 'nvdaControllerClient64.dll' -exec cp -v "${c
|
||||
sed -i "s/Crazy-Party-beta${oldVersion}/Crazy-Party-beta${newVersion}/" "$configFile"
|
||||
cp -v "${WINEPREFIX}/drive_c/Program Files/Crazy-Party-beta${oldVersion}/save.bin" "$HOME/.local/wine/crazy-party/drive_c/Program Files/Crazy-Party-beta${newVersion}/"
|
||||
cp -ruv "${WINEPREFIX}/drive_c/Program Files/Crazy-Party-beta${oldVersion}/"* "$HOME/.local/wine/crazy-party/drive_c/Program Files/Crazy-Party-beta${newVersion}/" 2> /dev/null
|
||||
rm -rf "${WINEPREFIX}/drive_c/Program Files/Crazy-Party-beta${oldVersion}/") | dialog --progressbox "updating Crazy Party, please wait..." -1 -1
|
||||
rm -rf "${WINEPREFIX}/drive_c/Program Files/Crazy-Party-beta${oldVersion}/") | agm_progressbox "Crazy Party Update" "Updating Crazy Party, please wait..."
|
||||
|
||||
exit 0
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/bin/bash
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# âe contents of this file are subject to the Common Public Attribution
|
||||
# License Version 1.0 (the âcenseâ you may not use this file except in
|
||||
@ -37,6 +37,10 @@
|
||||
# Works which are defined in the CPAL as a work which combines Covered Code
|
||||
# or portions thereof with code not governed by the terms of the CPAL.
|
||||
|
||||
|
||||
# Source dialog interface wrapper
|
||||
source "${0%/*}/../.includes/dialog-interface.sh"
|
||||
|
||||
cache="${XDG_CACHE_HOME:-$HOME/.cache}/audiogame-manager"
|
||||
updateURL="https://www.kaldobsky.com/audiogames"
|
||||
updateFiles=("rettou.zip")
|
||||
@ -47,7 +51,7 @@ for i in "${updateFiles[@]}" ; do
|
||||
rm -fv "${cache}/${i}"
|
||||
curl -L4 -C - --retry 10 --output "${cache}/$i" "${updateURL}/$i"
|
||||
unzip -o -d ~/".local/wine/aprone/drive_c/Program Files/rettou" "${cache}/${i}"
|
||||
done | dialog --progressbox "Updating Rettou, please wait..." -1 -1
|
||||
done | agm_progressbox "Rettou Update" "Updating Rettou, please wait..."
|
||||
|
||||
|
||||
exit 0
|
||||
|
@ -37,11 +37,15 @@
|
||||
# Works which are defined in the CPAL as a work which combines Covered Code
|
||||
# or portions thereof with code not governed by the terms of the CPAL.
|
||||
|
||||
|
||||
# Source dialog interface wrapper
|
||||
source "${0%/*}/../.includes/dialog-interface.sh"
|
||||
|
||||
cache="${XDG_CACHE_HOME:-$HOME/.cache}/audiogame-manager"
|
||||
url="https://stevend.net/downloads/scramble_win32.zip"
|
||||
(rm -v "${cache}/scramble_win32.zip"
|
||||
wget -O "${cache}/scramble_win32.zip" "$url" || { echo "Could not download file."; exit 1; }
|
||||
unzip -DDod "$HOME/.local/wine/scramble!/drive_c/Program Files" "${cache}/scramble_win32.zip"
|
||||
find ~/".local/wine/scramble!" -type f -name 'nvdaControllerClient32.dll' -exec cp -v "${cache}/nvdaControllerClient32.dll" "{}" \;) | dialog --progressbox "updating Scramble!, please wait..." -1 -1
|
||||
find ~/".local/wine/scramble!" -type f -name 'nvdaControllerClient32.dll' -exec cp -v "${cache}/nvdaControllerClient32.dll" "{}" \;) | agm_progressbox "Scramble Update" "Updating Scramble!, please wait..."
|
||||
|
||||
exit 0
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/bin/bash
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# âe contents of this file are subject to the Common Public Attribution
|
||||
# License Version 1.0 (the âcenseâ you may not use this file except in
|
||||
@ -37,19 +37,23 @@
|
||||
# Works which are defined in the CPAL as a work which combines Covered Code
|
||||
# or portions thereof with code not governed by the terms of the CPAL.
|
||||
|
||||
|
||||
# Source dialog interface wrapper
|
||||
source "${0%/*}/../.includes/dialog-interface.sh"
|
||||
|
||||
cache="${XDG_CACHE_HOME:-$HOME/.cache}/audiogame-manager"
|
||||
updateURL="https://www.kaldobsky.com/audiogames"
|
||||
updateFiles=("SwampPatch.zip")
|
||||
|
||||
|
||||
dialog --backtitle "Audiogame manager" --yesno "If you do not have a full 32 bit gstreamer installation, the Swamp music can cause stuttering and crashes. Would you like to remove the music directory after installation?" -1 -1 --stdout
|
||||
agm_yesno "Swamp Update" "Swamp Update" "If you do not have a full 32 bit gstreamer installation, the Swamp music can cause stuttering and crashes. Would you like to remove the music directory after installation?"
|
||||
deleteMusic=$?
|
||||
|
||||
# Back up configuration files.
|
||||
for i in losers.txt muted.txt scriptkeys.txt keyconfig.ini ; do
|
||||
cp -v ~/".local/wine/aprone/drive_c/Program Files/swamp/${i}" ~/".local/wine/aprone/drive_c/Program Files/swamp/${i}.agm"
|
||||
echo "${i} backed up as ${i}.agm"
|
||||
done | dialog --progressbox "Backing up configuration files. They can be found in your swamp directory." -1 -1
|
||||
done | agm_progressbox "Swamp Update" "Backing up configuration files. They can be found in your swamp directory."
|
||||
|
||||
sleep 3
|
||||
|
||||
@ -57,7 +61,7 @@ sleep 3
|
||||
for i in "${updateFiles[@]}" ; do
|
||||
wget -O "${cache}/$i" "${updateURL}/$i"
|
||||
unzip -o -d ~/".local/wine/aprone/drive_c/Program Files/swamp" "${cache}/${i}"
|
||||
done | dialog --progressbox "Updating Swamp, please wait..." -1 -1
|
||||
done | agm_progressbox "Swamp Update" "Updating Swamp, please wait..."
|
||||
|
||||
# Delete music if requested.
|
||||
if [[ $deleteMusic -eq 0 ]]; then
|
||||
|
Reference in New Issue
Block a user