From 270fe50aa22271c772d9fbcfbd31acf4dd1c77c7 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Fri, 15 Dec 2023 21:06:28 -0500 Subject: [PATCH] Started work on sound driver configuration. Jack is working, now for the hard part, alsa. --- tojam | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/tojam b/tojam index 87c5b37..ae1c055 100755 --- a/tojam +++ b/tojam @@ -116,6 +116,20 @@ configure_ninjam() { exit 0 fi case "${setting}" in + "sound driver") + soundDriver="$(dialog --yes-label "alsa" \ + --no-label "jack" \ + --yesno "Select a sound driver" -1 -1 --stdout)" + soundDriver=$? + [[ $? -eq 255 ]] && continue + soundDriver="${soundDriver/0/alsa}" + soundDriver="${soundDriver/1/jack}" + if [[ "${soundDriver}" == "jack" ]]; then + sed -i 's/^soundDriver=.*/soundDriver="jack"/' "${config}/config" && + dialog --msgbox "Sound driver set to jack." -1 -1 + continue + fi + ;; "username") userName="$(dialog --backtitle "Tojam" \ --inputbox "Enter User Name (letters, numbers, dash, and underscore accepted):" -1 -1 "${userName#*anonymous:}" --stdout)"