01: update config

This commit is contained in:
2026-03-21 12:45:05 -05:00
parent 546aefe946
commit 1e99c5133f
10 changed files with 892 additions and 120 deletions
+60
View File
@@ -0,0 +1,60 @@
#!/usr/bin/env sh
# wallpaper var
EnableWallDcol=0
ConfDir="${XDG_CONFIG_HOME:-$HOME/.config}"
CloneDir="$HOME/Hyprdots"
ThemeCtl="$ConfDir/hypr/theme.ctl"
cacheDir="$HOME/.cache/hyprdots"
# theme var
gtkTheme=`gsettings get org.gnome.desktop.interface gtk-theme | sed "s/'//g"`
gtkMode=`gsettings get org.gnome.desktop.interface color-scheme | sed "s/'//g" | awk -F '-' '{print $2}'`
# hypr var
hypr_border=`hyprctl -j getoption decoration:rounding | jq '.int'`
hypr_width=`hyprctl -j getoption general:border_size | jq '.int'`
# notification var
#ncolor="-h string:bgcolor:#191724 -h string:fgcolor:#faf4ed -h string:frcolor:#56526e"
#
#if [ "${gtkMode}" == "light" ] ; then
# ncolor="-h string:bgcolor:#f4ede8 -h string:fgcolor:#9893a5 -h string:frcolor:#908caa"
#fi
# pacman fns
pkg_installed()
{
local PkgIn=$1
if pacman -Qi $PkgIn &> /dev/null
then
#echo "${PkgIn} is already installed..."
return 0
else
#echo "${PkgIn} is not installed..."
return 1
fi
}
get_aurhlpr()
{
if pkg_installed yay
then
aurhlpr="yay"
elif pkg_installed paru
then
aurhlpr="paru"
fi
}
check(){
local Pkg_Dep=$(for PkgIn in "$@"; do ! pkg_installed $PkgIn && echo "$PkgIn"; done)
if [ -n "$Pkg_Dep" ]; then echo -e "$0 Dependencies:\n$Pkg_Dep"
read -p "ENTER to install (Other key: Cancel): " ans
if [ -z "$ans" ]; then get_aurhlpr ; $aurhlpr -S $Pkg_Dep
else echo "Skipping installation of packages" ;exit 1
fi
fi
}
+61
View File
@@ -0,0 +1,61 @@
#!/usr/bin/env sh
# Check if wlogout is already running
if pgrep -x "wlogout" > /dev/null
then
pkill -x "wlogout"
exit 0
fi
# set file variables
ScrDir=`dirname "$(realpath "$0")"`
source $ScrDir/globalcontrol.sh
wLayout="${XDG_CONFIG_HOME:-$HOME/.config}/wlogout/layout_$1"
wlTmplt="${XDG_CONFIG_HOME:-$HOME/.config}/wlogout/style_$1.css"
if [ ! -f $wLayout ] || [ ! -f $wlTmplt ] ; then
echo "ERROR: Config $1 not found..."
exit 1;
fi
# detect monitor res
x_mon=$(hyprctl -j monitors | jq '.[] | select(.focused==true) | .width')
y_mon=$(hyprctl -j monitors | jq '.[] | select(.focused==true) | .height')
hypr_scale=$(hyprctl -j monitors | jq '.[] | select (.focused == true) | .scale' | sed 's/\.//')
# scale config layout and style
case $1 in
1) wlColms=6
export mgn=$(( y_mon * 28 / hypr_scale ))
export hvr=$(( y_mon * 23 / hypr_scale )) ;;
2) wlColms=2
export x_mgn=$(( x_mon * 35 / hypr_scale ))
export y_mgn=$(( y_mon * 25 / hypr_scale ))
export x_hvr=$(( x_mon * 32 / hypr_scale ))
export y_hvr=$(( y_mon * 20 / hypr_scale )) ;;
esac
# scale font size
export fntSize=$(( y_mon * 2 / 100 ))
# detect gtk system theme
export BtnCol=`[ "$gtkMode" == "dark" ] && ( echo "white" ) || ( echo "black" )`
export WindBg=`[ "$gtkMode" == "dark" ] && ( echo "rgba(0,0,0,0.5)" ) || ( echo "rgba(255,255,255,0.5)" )`
if [ "$EnableWallDcol" -eq 1 ] ; then
export wbarTheme="Wall-Dcol"
else
export wbarTheme="${gtkTheme}"
fi
# eval hypr border radius
export active_rad=$(( hypr_border * 5 ))
export button_rad=$(( hypr_border * 8 ))
# eval config files
wlStyle=`envsubst < $wlTmplt`
# launch wlogout
wlogout -b $wlColms -c 0 -r 0 -m 0 --layout $wLayout --css <(echo "$wlStyle") --protocol layer-shell
+9
View File
@@ -0,0 +1,9 @@
#!/bin/bash
killall xdg-desktop-portal-hyprland
killall xdg-desktop-portal-gnome
killall xdg-desktop-portal-kde
killall xdg-desktop-portal-lxqt
killall xdg-desktop-portal-wlr
killall xdg-desktop-portal
/usr/lib/xdg-desktop-portal-hyprland &
/usr/lib/xdg-desktop-portal &
+21
View File
@@ -0,0 +1,21 @@
#!/bin/bash
# Custom resolution through xrandr (21:9)
xrandr --newmode "2560x1080" 677.75 2560 2784 3064 3568 1080 1083 1093 1188 -hsync +vsync
xrandr --newmode "2560x1080R" 373.00 2560 2608 2640 2720 1080 1083 1093 1144 +hsync -vsync
xrandr --addmode DP-1 2560x1080
xrandr --addmode DP-1 2560x1080R
# 3200x900 suggestion (32:9)
xrandr --newmode "3200x900" 704.50 3200 3472 3824 4448 900 903 913 991 -hsync +vsync
xrandr --addmode DP-1 3200x900
# 3200x1100 suggestion
xrandr --newmode "3200x1100" 863.75 3200 3480 3832 4464 1100 1103 1113 1210 -hsync +vsync
xrandr --addmode DP-1 3200x1100
# 3200x1100 suggestion (21:9)
xrandr --newmode "2100x900" 462.50 2100 2280 2512 2920 900 903 913 991 -hsync +vsync
xrandr --addmode DP-1 2100x900
sleep 2 && xrandr --output DP-1 --primary # Set primary monitor for xwayland