mirror of
https://github.com/Snigdha-OS/snigdhaos-system-installation.git
synced 2025-12-06 04:43:52 +01:00
38 lines
900 B
Bash
Executable File
38 lines
900 B
Bash
Executable File
#!/bin/bash
|
|
# set -e
|
|
|
|
# Author : Eshan Roy <eshan@snigdhaos.or>
|
|
# Author URL : https://eshanized.github.io/
|
|
|
|
echo
|
|
echo "--->> Start snigdhaos-fixes <<---"
|
|
echo
|
|
|
|
# Get the current desktop environment
|
|
desktop=$(ls /usr/share/xsessions/)
|
|
|
|
# Define a function to install and enable SDDM
|
|
install_sddm() {
|
|
echo "INSTALLED: LightDM/GDM [STATUS: ACTIVE]"
|
|
pacman -S sddm --noconfirm --needed
|
|
systemctl enable sddm.service -f
|
|
}
|
|
|
|
# Check for specific desktop environments and install SDDM if necessary
|
|
case $desktop in
|
|
ukui.desktop|deepin.desktop)
|
|
echo "Found : Lightm [STATUS: ACTIVE]"
|
|
install_sddm
|
|
;;
|
|
*)
|
|
# Check for other desktop environments
|
|
if [ -f /usr/bin/gnome-session ] || [ -f /usr/bin/startdde ] || [ -f /usr/bin/ukui-session ]; then
|
|
install_sddm
|
|
else
|
|
echo "Nothing To Do!!!"
|
|
fi
|
|
esac
|
|
|
|
echo
|
|
echo "--->> End snigdhaos-fixes <<---"
|
|
echo |