Update scripts/resetgui.sh
This commit is contained in:
@@ -1,9 +1,10 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
NO_FORMAT="\e[0m"
|
systemctl stop sddm
|
||||||
C_RED="\e[38;5;9m"
|
systemctl restart getty@tty1.service
|
||||||
if [ "$UID" -ne 0 ]; then
|
pkill -u admin -9 2>/dev/null || true
|
||||||
echo -e "${C_RED}This script must be run as root.${NO_FORMAT}"
|
pkill -f "lxqt" 2>/dev/null || true
|
||||||
exit 1
|
pkill -u admin -f "lxqt-" 2>/dev/null || true
|
||||||
fi
|
chvt 1
|
||||||
systemctl start backtotty &&
|
echo 'Restarting GUI'
|
||||||
sh /opt/scripts/initialisegui.sh
|
sleep 2
|
||||||
|
systemctl start sddm
|
||||||
Reference in New Issue
Block a user