From 0f4a0e8d78d0efa2ac6aa1af0e77a3b6e183161c Mon Sep 17 00:00:00 2001 From: Tobias Kessels Date: Tue, 18 Dec 2018 11:43:10 +0100 Subject: [PATCH] added some bashism to automountctl --- automountctl | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/automountctl b/automountctl index d039606..3b49cbc 100755 --- a/automountctl +++ b/automountctl @@ -28,29 +28,29 @@ fi case ${command} in on) echo "turning on" - if [ $mate -eq "1" ] ; then + if [[ $mate -eq "1" ]] ; then gsettings set org.mate.media-handling automount true gsettings set org.mate.media-handling automount-open true fi - if [ $gnome -eq "1" ] ; then + if [[ $gnome -eq "1" ]] ; then gsettings set org.gnome.desktop.media-handling automount true gsettings set org.gnome.desktop.media-handling automount-open true fi ;; off) echo "turning off" - if [ $mate -eq "1" ] ; then + if [[ $mate -eq "1" ]] ; then gsettings set org.mate.media-handling automount false gsettings set org.mate.media-handling automount-open false fi - if [ $gnome -eq "1" ] ; then + if [[ $gnome -eq "1" ]] ; then gsettings set org.gnome.desktop.media-handling automount false gsettings set org.gnome.desktop.media-handling automount-open false fi ;; *) echo "Status:" - if [ $mate -eq "1" ] ; then + if [[ $mate -eq "1" ]] ; then echo "# mate-settings found:" echo " - org.mate.media-handling automount :" echo -n " " @@ -60,7 +60,7 @@ off) gsettings get org.mate.media-handling automount-open fi - if [ $gnome -eq "1" ] ; then + if [[ $gnome -eq "1" ]] ; then echo "# gnome-settings found:" echo " - org.gnome.desktop.media-handling automount :" echo -n " "