mirror of
https://github.com/brain-hackers/brain-config.git
synced 2025-02-01 16:20:08 +09:00
Make Wayland switching more robust
This commit is contained in:
parent
2ef9a3a194
commit
0319d1c799
6
debian/changelog
vendored
6
debian/changelog
vendored
@ -1,3 +1,9 @@
|
|||||||
|
raspi-config (20220506) bullseye; urgency=medium
|
||||||
|
|
||||||
|
* Modify Wayland switching to work with AccountSettings
|
||||||
|
|
||||||
|
-- Simon Long <simon@raspberrypi.com> Fri, 06 May 2022 14:07:57 +0100
|
||||||
|
|
||||||
raspi-config (20220425) bullseye; urgency=medium
|
raspi-config (20220425) bullseye; urgency=medium
|
||||||
|
|
||||||
* Tidy hardware detection functions
|
* Tidy hardware detection functions
|
||||||
|
14
raspi-config
14
raspi-config
@ -2035,7 +2035,7 @@ do_glamor() {
|
|||||||
do_wayland() {
|
do_wayland() {
|
||||||
DEFAULT=--defaultno
|
DEFAULT=--defaultno
|
||||||
CURRENT=0
|
CURRENT=0
|
||||||
if grep -q "^user-session=LXDE-pi" /etc/lightdm/lightdm.conf ; then
|
if grep -q "^user-session=LXDE-pi-wayland" /etc/lightdm/lightdm.conf ; then
|
||||||
DEFAULT=
|
DEFAULT=
|
||||||
CURRENT=1
|
CURRENT=1
|
||||||
fi
|
fi
|
||||||
@ -2049,10 +2049,18 @@ do_wayland() {
|
|||||||
ASK_TO_REBOOT=1
|
ASK_TO_REBOOT=1
|
||||||
fi
|
fi
|
||||||
if [ $RET -eq 0 ]; then
|
if [ $RET -eq 0 ]; then
|
||||||
sed /etc/lightdm/lightdm.conf -i -e "s/^#\\?user-session.*/user-session=LXDE-pi/"
|
sed /etc/lightdm/lightdm.conf -i -e "s/^#\\?user-session.*/user-session=LXDE-pi-wayland/"
|
||||||
|
sed /etc/lightdm/lightdm.conf -i -e "s/^#\\?autologin-session.*/autologin-session=LXDE-pi-wayland/"
|
||||||
|
if [ -e "/var/lib/AccountsService/users/$USER" ] ; then
|
||||||
|
sed "/var/lib/AccountsService/users/$USER" -i -e "s/XSession=.*/XSession=LXDE-pi-wayland/"
|
||||||
|
fi
|
||||||
STATUS=enabled
|
STATUS=enabled
|
||||||
elif [ $RET -eq 1 ]; then
|
elif [ $RET -eq 1 ]; then
|
||||||
sed /etc/lightdm/lightdm.conf -i -e "s/user-session.*/#user-session=LXDE-pi/"
|
sed /etc/lightdm/lightdm.conf -i -e "s/^#\\?user-session.*/user-session=LXDE-pi-x/"
|
||||||
|
sed /etc/lightdm/lightdm.conf -i -e "s/^#\\?autologin-session.*/autologin-session=LXDE-pi-x/"
|
||||||
|
if [ -e "/var/lib/AccountsService/users/$USER" ] ; then
|
||||||
|
sed "/var/lib/AccountsService/users/$USER" -i -e "s/XSession=.*/XSession=LXDE-pi-x/"
|
||||||
|
fi
|
||||||
STATUS=disabled
|
STATUS=disabled
|
||||||
else
|
else
|
||||||
return $RET
|
return $RET
|
||||||
|
Loading…
Reference in New Issue
Block a user