about summary refs log tree commit diff
path: root/dracut/display-manager-autologin.sh
diff options
context:
space:
mode:
authorChristian Neukirchen <chneukirchen@gmail.com>2015-10-09 15:24:32 +0200
committerChristian Neukirchen <chneukirchen@gmail.com>2015-10-09 15:43:55 +0200
commit44722b79e2f31c0c51bd2fc8c8d43c0009d79529 (patch)
tree5fc9fce8937199de06e2c22ad781e59fa654dfd2 /dracut/display-manager-autologin.sh
parenta25ced5c198fff963ba7b7e9b613059e756374c0 (diff)
parentcb2510b3791091fb54681cee451eb7ec24e0b266 (diff)
downloadhrmpf-44722b79e2f31c0c51bd2fc8c8d43c0009d79529.tar.gz
hrmpf-44722b79e2f31c0c51bd2fc8c8d43c0009d79529.tar.xz
hrmpf-44722b79e2f31c0c51bd2fc8c8d43c0009d79529.zip
Merge remote-tracking branch 'origin/master'
* origin/master: (136 commits)
  dracut/services: don't autostart dmeventd, lvmetad and mdadm.
  mklive: fix guessing linux kernel pkgname.
  fix set_keymap rc.conf
  installer.sh: fix static IP settings in menu_install
  build-arm-images: PLATFORM can be overrided now.
  build-rootfs: build musl rootfs too; PLATFORMS can be overrided now.
  build-x86-images: added lxqt image.
  dracut/dm-autologin: autostart lxqt if available.
  mkrootfs: add dockstar support
  mklive: install GRUB EFI loader as EFI/BOOT/BOOTX64.EFI.
  build-x86-images: add gnome-keyring to cinnamon/mate/xfce images.
  build-x86-images: add firefox now it's available for musl.
  build-arm-images: respect musl targets.
  mkimage: consistently redirect std{err,out} to /dev/null with dd(1).
  build-arm-images: disable cubietruck for now; does not boot.
  build-arm-images: build all ARM images for glibc and musl.
  mkrootfs: get rid of pixz; fix rpi target arch.
  mkrootfs: set cachedir to $PWD/xbps-cachedir-<arch>; misc tweaks for musl.
  mkrootfs: update for musl support.
  build-x86-images: do not build the kde image; does not work yet.
  ...
Diffstat (limited to 'dracut/display-manager-autologin.sh')
-rw-r--r--dracut/display-manager-autologin.sh18
1 files changed, 18 insertions, 0 deletions
diff --git a/dracut/display-manager-autologin.sh b/dracut/display-manager-autologin.sh
index c667e21..4d41164 100644
--- a/dracut/display-manager-autologin.sh
+++ b/dracut/display-manager-autologin.sh
@@ -21,6 +21,12 @@ if [ -d ${NEWROOT}/etc/gdm ]; then
     fi
 fi
 
+# Configure KDM autologin
+if [ -e ${NEWROOT}/etc/kdm/kdmrc ]; then
+    sed -i -e "s|^\#\(AutoLoginEnable=\).*|\1|" ${NEWROOT}/etc/kdm/kdmrc
+    sed -i -e "s|^\#\(AutoLoginUser=\).*|\1$USERNAME|" ${NEWROOT}/etc/kdm/kdmrc
+fi
+
 # Configure lightdm autologin.
 if [ -r ${NEWROOT}/etc/lightdm.conf ]; then
     sed -i -e "s|^\#\(default-user=\).*|\1$USERNAME|" \
@@ -34,5 +40,17 @@ if [ -r ${NEWROOT}/etc/lxdm/lxdm.conf ]; then
     sed -e "s,.*autologin.*=.*,autologin=$USERNAME," -i ${NEWROOT}/etc/lxdm/lxdm.conf
     if [ -x ${NEWROOT}/usr/bin/enlightenment_start ]; then
         sed -e "s,.*session.*=.*,session=/usr/bin/enlightenment_start," -i ${NEWROOT}/etc/lxdm/lxdm.conf
+    elif [ -x ${NEWROOT}/usr/bin/startxfce4 ]; then
+        sed -e "s,.*session.*=.*,session=/usr/bin/startxfce4," -i ${NEWROOT}/etc/lxdm/lxdm.conf
+    elif [ -x ${NEWROOT}/usr/bin/mate-session ]; then
+        sed -e "s,.*session.*=.*,session=/usr/bin/mate-session," -i ${NEWROOT}/etc/lxdm/lxdm.conf
+    elif [ -x ${NEWROOT}/usr/bin/cinnamon-session ]; then
+        sed -e "s,.*session.*=.*,session=/usr/bin/cinnamon-session," -i ${NEWROOT}/etc/lxdm/lxdm.conf
+    elif [ -x ${NEWROOT}/usr/bin/i3 ]; then
+        sed -e "s,.*session.*=.*,session=/usr/bin/i3," -i ${NEWROOT}/etc/lxdm/lxdm.conf
+    elif [ -x ${NEWROOT}/usr/bin/startlxde ]; then
+        sed -e "s,.*session.*=.*,session=/usr/bin/startlxde," -i ${NEWROOT}/etc/lxdm/lxdm.conf
+    elif [ -x ${NEWROOT}/usr/bin/startlxqt ]; then
+        sed -e "s,.*session.*=.*,session=/usr/bin/startlxqt," -i ${NEWROOT}/etc/lxdm/lxdm.conf
     fi
 fi