fixed dialout function

tweaked vara setup script for more testing
This commit is contained in:
tb14
2022-11-05 16:25:38 -05:00
parent e0944cef26
commit cdb8a5b85b
2 changed files with 20 additions and 3 deletions
+19 -3
View File
@@ -477,14 +477,30 @@ echo "100% Complete"
function add_dialout() { function add_dialout() {
if [[ $PLAT = "Linuxmint" ]]; then if [[ $PLAT = "Linuxmint" ]]; then
if $(id | grep dialout); then CHK_DIALOUT=$(id -nG | grep dialout)
echo "User already a member of Dialout"; return
else if [ -z "$CHK_DIALOUT" ]; then
echo "Adding user to dialout group" echo "Adding user to dialout group"
sudo usermod -a -G dialout $USER || sudo usermod -a -G dialout $USER ||
{ ERRCODE="Unable to add user to dialout group. You will need to run sudo usermod -a -G dialout $USER"; errors; return; } { ERRCODE="Unable to add user to dialout group. You will need to run sudo usermod -a -G dialout $USER"; errors; return; }
else
echo "User already a member of dialout group."
fi fi
fi fi
MYUSER=$(whoami)
CHK_DIALOUT=$(id -nG | grep dialout)
CHK_TTY=$(id -nG | grep tty)
CHK_AUDIO=$(id -nG | grep audio)
if [ -z "$CHK_DIALOUT" ]; then
echo "Adding user to dialout group"
sudo usermod -a -G dialout $MYUSER ||
{ ERRCODE="Failed to add user to dialout group"; errors; }
else
echo "User already in dialout group"
fi
} }
+1
View File
@@ -2,6 +2,7 @@
- Testing g++ dependency for hamlib - Testing g++ dependency for hamlib
- Removed auto removal of source directories. - Removed auto removal of source directories.
- Added VARIM to install - Added VARIM to install
- Tweaked dialout add function
# Version 0.7.4.2 # Version 0.7.4.2
- Pulling ardopc from gitlab folder due to website release version issues. - Pulling ardopc from gitlab folder due to website release version issues.