From 876d787e0a2e7381bfa91d49c021d4a9c12d470d Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Fri, 9 Jan 2026 19:40:17 -0500 Subject: [PATCH] Menu items are alphabetized again. --- .includes/bottle.sh | 2 +- audiogame-manager.sh | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.includes/bottle.sh b/.includes/bottle.sh index a3b5518..c57a171 100644 --- a/.includes/bottle.sh +++ b/.includes/bottle.sh @@ -229,7 +229,7 @@ add_launcher() { done if ! grep -F -q -x "${launchSettings}" "${configFile}" 2> /dev/null ; then echo "${launchSettings}" >> "${configFile}" - sort -o "${configFile}" "${configFile}" + sort -t '|' -k3,3f -o "${configFile}" "${configFile}" # Remove .lnk files because they don't work. find ~/Desktop -type f -iname '*.lnk' -exec bash -c ' for f ; do diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 6aa5838..bde45d4 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -205,7 +205,7 @@ game_removal() { # shellcheck source=.includes/bottle.sh source "${scriptDir}/.includes/bottle.sh" # Modern wine is unified - no architecture-specific wine executables needed - mapfile -t lines < <(sed -e '/^$/d' -e '/^[[:space:]]*#/d' "${configFile}" 2> /dev/null) + mapfile -t lines < <(sed -e '/^$/d' -e '/^[[:space:]]*#/d' "${configFile}" 2> /dev/null | sort -t '|' -k3,3f) if [[ ${#lines} -eq 0 ]]; then agm_msgbox "Audio Game Removal" "" "No games found." exit 0 @@ -276,7 +276,7 @@ kill_game() { # shellcheck source=.includes/bottle.sh source "${scriptDir}/.includes/bottle.sh" # Modern wine is unified - no architecture-specific wine executables needed - mapfile -t lines < <(sed '/^$/d' "${configFile}" 2> /dev/null) + mapfile -t lines < <(sed '/^$/d' "${configFile}" 2> /dev/null | sort -t '|' -k3,3f) if [[ ${#lines} -eq 0 ]]; then agm_msgbox "Audio Game Killer" "" "No games found." exit 0 @@ -484,7 +484,7 @@ game_launcher() { # Replace NVDA controller client DLLs in wine64 bottle update_nvda_dlls - mapfile -t lines < <(sed -e '/^$/d' -e '/^ *#/d' "${configFile}" 2> /dev/null) + mapfile -t lines < <(sed -e '/^$/d' -e '/^ *#/d' "${configFile}" 2> /dev/null | sort -t '|' -k3,3f) if [[ ${#lines} -eq 0 ]]; then agm_msgbox "Audio Game Launcher" "" "Install some games first." exit 0