configure-stormux/.includes/screenreader.sh

21 lines
719 B
Bash
Raw Normal View History

#!/bin/bash
2021-10-23 14:33:47 -04:00
if [[ "$(systemctl is-active fenrirscreenreader.service)" == "active" ]]; then
screenreader="speakup"
else
screenreader="fenrir"
fi
continue="$(yesno "Do you want to switch the active console screen reader to ${screenreader^}?")"
if [[ "$continue" == "Yes" ]]; then
if [[ "$screenreader" == "speakup" ]]; then
install_package espeakup
sudo "${sudoFlags[@]}" systemctl disable --now fenrirscreenreader.service
sudo "${sudoFlags[@]}" systemctl enable --now espeakup.service
fi
if [[ "$screenreader" == "fenrir" ]]; then
sudo "${sudoFlags[@]}" systemctl disable --now espeakup.service
sudo "${sudoFlags[@]}" systemctl enable --now fenrirscreenreader.service
fi
fi