diff options
author | BlackNoxis <steven.darklight@gmail.com> | 2015-06-28 11:21:58 +0300 |
---|---|---|
committer | BlackNoxis <steven.darklight@gmail.com> | 2015-06-28 11:22:07 +0300 |
commit | d5d2bce0c7dc092c6737d4f3eaa1f02e4892ee00 (patch) | |
tree | 1da51262b74ff29c82b742c14931fadfc9cb7f09 | |
parent | bbe8295a997f3f5ae2ce735a5556c784002ef073 (diff) |
refacut graphical_start.sh intr-o forma mai optima
-rw-r--r-- | graphical_start.sh | 30 |
1 files changed, 14 insertions, 16 deletions
diff --git a/graphical_start.sh b/graphical_start.sh index d14c0b1..a63bc5f 100644 --- a/graphical_start.sh +++ b/graphical_start.sh @@ -1,18 +1,16 @@ #!/bin/bash -setup_displaymanager() { - # determine what is the login manager - if [ -n "$(equo match --installed gnome-base/gdm -qv)" ]; then - systemctl start gdm - elif [ -n "$(equo match --installed lxde-base/lxdm -qv)" ]; then - systemctl start lxdm - elif [ -n "$(equo match --installed x11-misc/lightdm-base -qv)" ]; then - systemctl start lightdm - elif [ -n "$(equo match --installed kde-base/kdm -qv)" ]; then - systemctl start kdm - elif [ -n "$(equo match --installed x11-misc/slim -qv)" ]; then - systemctl start slim - else - systemctl start xdm - fi -} + +if [ -n "$(equo match --installed gnome-base/gdm -qv)" ]; then + systemctl start gdm +elif [ -n "$(equo match --installed lxde-base/lxdm -qv)" ]; then + systemctl start lxdm +elif [ -n "$(equo match --installed x11-misc/lightdm-base -qv)" ]; then + systemctl start lightdm +elif [ -n "$(equo match --installed kde-base/kdm -qv)" ]; then + systemctl start kdm +elif [ -n "$(equo match --installed x11-misc/slim -qv)" ]; then + systemctl start slim +else + systemctl start xdm +fi |