This commit is contained in:
sankalp committed 2024-08-10 13:57:04 +05:45
1 parent 9ef3878430
commit 7ce9531f32
7 files changed
+241 -1

No files matched your search

+3
View File
@@ -0,0 +1,3 @@
#!/bin/bash
"$HOME"/dotfiles/sddm/scripts/wallpaper.sh 1>/dev/null
+38
View File
@@ -0,0 +1,38 @@
import QtQuick 2.15
import QtQuick.Controls 2.15
import QtQuick.Window 2.15
import "./components"
Rectangle {
id: root
height: Screen.height
width: Screen.width
Image {
anchors { fill: parent }
source: config.BgSource
fillMode: Image.PreserveAspectCrop
clip: true
}
Item {
anchors {
fill: parent
margins: config.Padding
}
DateTimePanel {
anchors {
top: parent.top
right: parent.right
}
}
LoginPanel {
anchors { fill: parent }
}
}
}
+12
View File
@@ -0,0 +1,12 @@
#!/bin/bash
figlet "Disable SDDM"
if [ -f /etc/systemd/system/display-manager.service ]; then
if gum confirm "Do you want to disable the current display manager?"; then
sudo rm /etc/systemd/system/display-manager.service
echo ":: Current display manager removed."
echo ":: Please reboot your system."
fi
else
echo ":: No Display Manager enabled."
fi
sleep 3
+12
View File
@@ -0,0 +1,12 @@
#!/bin/bash
figlet "Enable SDDM"
if [ -f /etc/systemd/system/display-manager.service ]; then
echo ":: Display Manager is already enabled."
else
if gum confirm "Do you want to enable SDDM as your display manager?"; then
sudo systemctl enable sddm.service
echo ":: Display manager SDDM has been enabled."
echo ":: Please reboot your system!"
fi
fi
sleep 3
+31
View File
@@ -0,0 +1,31 @@
#!/bin/bash
cache_file="$HOME/.cache/current_wallpaper"
if [ ! -d /etc/sddm.conf.d/ ]; then
sudo mkdir /etc/sddm.conf.d
echo "Folder /etc/sddm.conf.d created."
fi
cp $HOME/dotfiles/sddm/sddm.conf /etc/sddm.conf.d/
cp $HOME/dotfiles/sddm/sddm.conf /etc/
if [ "$1" != "init" ]; then
echo "File /etc/sddm.conf.d/sddm.conf updated."
fi
current_wallpaper=$(cat "$cache_file")
extension="${current_wallpaper##*.}"
cp $current_wallpaper /usr/share/sddm/themes/corners/backgrounds/current_wallpaper.$extension
if [ "$1" != "init" ]; then
echo "Current wallpaper copied into /usr/share/sddm/themes/corners/backgrounds/"
fi
new_wall=$(echo $current_wallpaper | sed "s|$HOME/wallpaper/||g")
cp $HOME/.cache/material/colors-sddm-style.conf /usr/share/sddm/themes/corners/theme.conf
sed -i 's/CURRENTWALLPAPER/'"current_wallpaper.$extension"'/' /usr/share/sddm/themes/corners/theme.conf
if [ "$1" != "init" ]; then
echo "File theme.conf updated in /usr/share/sddm/themes/corners/"
echo "DONE! Please logout to test sddm."
fi
+138
View File
@@ -0,0 +1,138 @@
[Autologin]
# Whether sddm should automatically log back into sessions when they exit
Relogin=false
# Name of session file for autologin session (if empty try last logged in)
Session=
# Username for autologin session
User=
[General]
# Which display server should be used.
# Valid values are: x11, x11-user, wayland. Wayland support is experimental
DisplayServer=x11
# Comma-separated list of environment variables to be set
GreeterEnvironment=
# Halt command
HaltCommand=/usr/bin/systemctl poweroff
# Input method module
InputMethod=
# Comma-separated list of Linux namespaces for user session to enter
Namespaces=
# Initial NumLock state. Can be on, off or none.
# If property is set to none, numlock won't be changed
# NOTE: Currently ignored if autologin is enabled.
Numlock=none
# Reboot command
RebootCommand=/usr/bin/systemctl reboot
[Theme]
# Current theme name
Current=corners
# Cursor size used in the greeter
CursorSize=24
# Cursor theme used in the greeter
CursorTheme=Bibata-Modern-Ice
# Number of users to use as threshold
# above which avatars are disabled
# unless explicitly enabled with EnableAvatars
DisableAvatarsThreshold=7
# Enable display of custom user avatars
EnableAvatars=false
# Global directory for user avatars
# The files should be named <username>.face.icon
FacesDir=/usr/share/sddm/faces
# Font used in the greeter
Font=
# Theme directory path
# ThemeDir=/usr/share/sddm/themes
ThemeDir=/usr/share/sddm/themes
[Users]
# Default $PATH for logged in users
DefaultPath=/usr/local/sbin:/usr/local/bin:/usr/bin
# Comma-separated list of shells.
# Users with these shells as their default won't be listed
HideShells=
# Comma-separated list of users that should not be listed
HideUsers=
# Maximum user id for displayed users
MaximumUid=60513
# Minimum user id for displayed users
MinimumUid=1000
# Remember the session of the last successfully logged in user
RememberLastSession=true
# Remember the last successfully logged in user
RememberLastUser=true
# When logging in as the same user twice, restore the original session, rather than create a new one
ReuseSession=true
[Wayland]
# Path of the Wayland compositor to execute when starting the greeter
CompositorCommand=weston --shell=fullscreen-shell.so
# Enable Qt's automatic high-DPI scaling
EnableHiDPI=true
# Path to a script to execute when starting the desktop session
SessionCommand=/usr/share/sddm/scripts/wayland-session
# Comma-separated list of directories containing available Wayland sessions
SessionDir=/usr/local/share/wayland-sessions,/usr/share/wayland-sessions
# Path to the user session log file
SessionLogFile=.local/share/sddm/wayland-session.log
[X11]
# Path to a script to execute when starting the display server
DisplayCommand=/usr/share/sddm/scripts/Xsetup
# Path to a script to execute when stopping the display server
DisplayStopCommand=/usr/share/sddm/scripts/Xstop
# Enable Qt's automatic high-DPI scaling
EnableHiDPI=true
# Arguments passed to the X server invocation
ServerArguments=-nolisten tcp
# Path to X server binary
ServerPath=/usr/bin/X
# Path to a script to execute when starting the desktop session
SessionCommand=/usr/share/sddm/scripts/Xsession
# Comma-separated list of directories containing available X sessions
SessionDir=/usr/local/share/xsessions,/usr/share/xsessions
# Path to the user session log file
SessionLogFile=.local/share/sddm/xorg-session.log
# Path to Xephyr binary
XephyrPath=/usr/bin/Xephyr
+7 -1
View File
@@ -101,6 +101,7 @@ pkg=(
hyprlock
hypridle
sddm
sddm-theme-corners-git
xdg-user-dirs
# AGS
@@ -492,7 +493,12 @@ sudo tee /etc/sddm.conf.d/theme.conf <<EOF
[Theme]
Current=corners
EOF
sudo cp -f ~/dotfiles/extras/theme.conf /usr/share/sddm/themes/corners/
sudo cp $HOME/dotfiles/sddm/sddm.conf /etc/sddm.conf.d/
sudo cp $HOME/dotfiles/sddm/sddm.conf /etc/
sudo chmod 777 /etc/sddm.conf.d/sddm.conf
sudo chmod 777 /etc/sddm.conf
sudo chmod -R 777 /usr/share/sddm/themes/corners/
"$HOME"/dotfiles/sddm/scripts/wallpaper.sh
simulate_output "Setting theme for sddm..."
simulate_output "[ \e[32mOK\e[0m ] SDDM theme set to 'corners'"