43 lines
1.1 KiB
Bash
Executable File
43 lines
1.1 KiB
Bash
Executable File
#!/bin/bash
|
|
|
|
sleep 5
|
|
|
|
ref=$(kdialog --progressbar "The computer is being configured. Wait until the desktop loads" 100 --title "Waiting for the computer to complete setup")
|
|
qdbus $ref org.kde.kdialog.ProgressDialog.autoClose true
|
|
|
|
theme="com.github.Melawy.Melawy-round-gray.Nier-A2.desktop"
|
|
|
|
plasma-apply-lookandfeel -a "$theme" --resetLayout
|
|
|
|
qdbus $ref Set org.kde.kdialog.ProgressDialog value 10
|
|
|
|
if [ "$(whoami)" != "liveuser" ]; then
|
|
sleep 5
|
|
if [ -f "$HOME/.config/autostart/reset-layout.desktop" ]; then
|
|
rm "$HOME/.config/autostart/reset-layout.desktop"
|
|
fi
|
|
# rm "$HOME/.local/bin/reset-layout.sh"
|
|
fi
|
|
|
|
qdbus $ref Set org.kde.kdialog.ProgressDialog value 20
|
|
sleep 1
|
|
|
|
normal_process=$(ps -eo pcpu,stat,comm | grep plasmashell | grep 'S<sl')
|
|
|
|
if [ -z "$normal_process" ]; then
|
|
echo "Restart plasma-plasmashell"
|
|
systemctl --user restart plasma-plasmashell
|
|
fi
|
|
|
|
qdbus $ref Set org.kde.kdialog.ProgressDialog value 30
|
|
sleep 1
|
|
|
|
notify-send -t 5000 -a "Theme is" "$theme" "$(date '+%Y.%m.%d %H:%M:%S')"
|
|
|
|
qdbus $ref Set org.kde.kdialog.ProgressDialog value 100
|
|
sleep 1
|
|
|
|
qdbus $ref org.kde.kdialog.ProgressDialog.close
|
|
|
|
echo "Ready"
|