adding wlogout

replacing swaybg with swww
This commit is contained in:
nevaforget 2024-02-27 20:09:32 +01:00
parent 4d6250e630
commit 62775e9d87
3 changed files with 87 additions and 3 deletions

36
etc/wlogout/layout Normal file
View File

@ -0,0 +1,36 @@
{
"label" : "lock",
"action" : "swaylock -c #2e3440 -e",
"text" : "Lock",
"keybind" : "l"
}
{
"label" : "hibernate",
"action" : "systemctl hibernate",
"text" : "Hibernate",
"keybind" : "h"
}
{
"label" : "logout",
"action" : "loginctl terminate-user $USER",
"text" : "Logout",
"keybind" : "e"
}
{
"label" : "shutdown",
"action" : "systemctl poweroff",
"text" : "Shutdown",
"keybind" : "s"
}
{
"label" : "suspend",
"action" : "systemctl suspend",
"text" : "Suspend",
"keybind" : "u"
}
{
"label" : "reboot",
"action" : "systemctl reboot",
"text" : "Reboot",
"keybind" : "r"
}

46
etc/wlogout/style.css Normal file
View File

@ -0,0 +1,46 @@
* {
background-image: none;
}
window {
background-color: rgba(12, 12, 12, 0.9);
}
button {
color: #acb0d0;
background-color: #1E1E1E;
border-radius: 10px;
border:5px solid black;
background-repeat: no-repeat;
background-position: center;
background-size: 25%;
outline-style: none;
}
button:focus, button:active, button:hover {
border:5px solid black;
background-color: #2e3440;
outline-style: none;
}
#lock {
background-image: image(url("/usr/share/wlogout/icons/lock.png"), url("/usr/local/share/wlogout/icons/lock.png"));
}
#logout {
background-image: image(url("/usr/share/wlogout/icons/logout.png"), url("/usr/local/share/wlogout/icons/logout.png"));
}
#suspend {
background-image: image(url("/usr/share/wlogout/icons/suspend.png"), url("/usr/local/share/wlogout/icons/suspend.png"));
}
#hibernate {
background-image: image(url("/usr/share/wlogout/icons/hibernate.png"), url("/usr/local/share/wlogout/icons/hibernate.png"));
}
#shutdown {
background-image: image(url("/usr/share/wlogout/icons/shutdown.png"), url("/usr/local/share/wlogout/icons/shutdown.png"));
}
#reboot {
background-image: image(url("/usr/share/wlogout/icons/reboot.png"), url("/usr/local/share/wlogout/icons/reboot.png"));
}

View File

@ -169,7 +169,7 @@ function post_always {
echo " "
echo "-"
echo "Running post installations steps"
echo "Running updatedb"
sudo updatedb
echo " "
echo " "
@ -382,12 +382,14 @@ function inst_hypr {
read confirm_hypr
if [[ $confirm_hypr == "Y" ]];
then
declare -a pkg_list=(wayland xorg-xwayland hyprland swaybg waypaper-git xdg-desktop-portal-hyprland wdisplays waybar nwg-look cliphist swaylock-effects)
declare -a pkg_list=(wayland xorg-xwayland hyprland swaybg waypaper-git xdg-desktop-portal-hyprland wdisplays waybar nwg-look cliphist swaylock-effects wlogout)
for key in "${pkg_list[@]}"
do
pkg_inst $key
done
sudo cp -Rf $MOONARCH_DIR/etc/wlogout /etc/
cp -Rf $MOONARCH_DIR/home/config/hypr $HOME/.config/hypr
chown $USER:$USER $HOME/.config/hypr
cp -Rf $MOONARCH_DIR/home/config/waybar $HOME/.config/waybar
@ -400,7 +402,7 @@ function inst_hypr {
cp -Rf $MOONARCH_DIR/home/config/waypaper $HOME/.config/waypaper
chown -R $USER:$USER $HOME/.config/waypaper
sed -i "s|USERNAME|${USER}|g" $HOME/.config/waypaper/config.ini
swaybg -i $WALLPAPER_DIR/MonarchOS.png -m fill
swww img $WALLPAPER_DIR/MonarchOS.png
fi
}