Skip to content

Commit c8df0e9

Browse files
committed
Add default theme to login screen
1 parent 8e37b92 commit c8df0e9

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,33 @@
11
#!/usr/bin/env bash
22
set -e
33

4+
# Remove the old Debian branding/theme package
45
apt purge -y desktop-base
6+
7+
# Generate a default SDDM config if none exists
8+
if [ ! -f /etc/sddm.conf ]; then
9+
sddm --example-config > /etc/sddm.conf
10+
fi
11+
12+
# Set the Breeze Dark theme as the current SDDM theme
13+
sed -i '/^\[Theme\]/,/^\[/ s/^Current=.*/Current=breeze/' /etc/sddm.conf || true
14+
sed -i '/^\[Theme\]/,/^\[/ s/^#Current=.*/Current=breeze/' /etc/sddm.conf || true
15+
16+
# In case the [Theme] section doesn't exist, append it
17+
if ! grep -q "^\[Theme\]" /etc/sddm.conf; then
18+
echo -e "\n[Theme]\nCurrent=breeze" >> /etc/sddm.conf
19+
fi
20+
21+
# Force the dark variant in KDE settings if available
22+
mkdir -p /etc/sddm.conf.d
23+
cat > /etc/sddm.conf.d/theme.conf <<EOF
24+
[Theme]
25+
Current=breeze
26+
CursorTheme=breeze_cursors
27+
Font=Noto Sans,10,-1,5,50,0,0,0,0,0
28+
EnableHiDPI=true
29+
EOF
30+
31+
# Restart SDDM to apply changes
32+
systemctl restart sddm
33+

0 commit comments

Comments
 (0)