diff --git a/.config/nvim b/.config/nvim index c07c881..17d7beb 160000 --- a/.config/nvim +++ b/.config/nvim @@ -1 +1 @@ -Subproject commit c07c881baeb8f878db656a93437d785b83340be7 +Subproject commit 17d7beb6f899a61d845ee36df2465ad3fcf494fc diff --git a/.config/shell/profile b/.config/shell/profile index fdaf0e4..9bf50fc 100644 --- a/.config/shell/profile +++ b/.config/shell/profile @@ -44,7 +44,7 @@ export ELECTRUMDIR="${XDG_DATA_HOME:-$HOME/.local/share}/electrum" # Other program settings export DICS="/usr/share/stardicts/dic/" -export SUDO_ASK_PASS="$HOME/.local/bin/dmenupass" +export SUDO_ASKPASS="$HOME/.local/bin/dmenupass" export FZF_DEFAULT_OPTS="--layout=reverse --height 40%" export LESS=-R export LESS_TERMCAP_mb="$(printf '%b' '\e[1;31m')" diff --git a/.config/x11/xprofile b/.config/x11/xprofile index f0017d3..dbe49c9 100644 --- a/.config/x11/xprofile +++ b/.config/x11/xprofile @@ -3,8 +3,16 @@ # This file runs when a DM logs you into a graphical session. # If you use startx/xinit, this file will also be sourced. -# xrdb ${XDG_CONFIG_HOME:-$HOME/.config}/x11/xresources & # Use Xresources colors/settings on startup -setbg & # set the background +xrdb ${XDG_CONFIG_HOME:-$HOME/.config}/x11/xresources # Use Xresources colors/settings on startup + +if [ -f "${XDG_CONFIG_HOME:-$HOME/.config}/x11/.DPI" ]; then + DPI="$(cat "${XDG_CONFIG_HOME:-$HOME/.config}/x11/.DPI")" + echo "Xft.dpi: $DPI" | xrdb -merge + xrandr --dpi "$DPI" +fi + +setbg ~/Scarif/Pictures/Wallpapers/Dual\ 4K & # set the background +enpass & # start password manager xcompmgr & # xcompmgr for transparency dunst & # dunst for notifications xset r rate 300 50 & # Speed xrate up diff --git a/.config/x11/xresources b/.config/x11/xresources index 03f1e52..8063ba7 100644 --- a/.config/x11/xresources +++ b/.config/x11/xresources @@ -1,8 +1,8 @@ !! Transparency (0-1): -*.alpha: 0.8 +*.alpha: 0.9 !! Set a default font and font size as below: -*.font: FiraCode:size=15 +*.font: FiraCode:size=13 /* name dark light */ /* black 0 8 */ diff --git a/.local/bin/setbg b/.local/bin/setbg index 383a4a3..f1ff4f4 100755 --- a/.local/bin/setbg +++ b/.local/bin/setbg @@ -16,9 +16,11 @@ case "$(file --mime-type -b "$trueloc")" in *) notify-send "Error" "Not a valid image." ; exit 1;; esac +[ -z "$trueloc" ] && trueloc="$(readlink -f "$bgloc")" + # If pywal is installed, use it. command -v wal >/dev/null 2>&1 && wal -i "$trueloc" -n -o "${XDG_CONFIG_HOME:-$HOME/.config}/wal/postrun" >/dev/null 2>&1 && - pidof dwm >/dev/null && xdotool key super+F12 + dwmc xrdb xwallpaper --zoom "$bgloc" diff --git a/.local/bin/setup/maptool b/.local/bin/setup/maptool deleted file mode 100755 index 2df7b69..0000000 --- a/.local/bin/setup/maptool +++ /dev/null @@ -1,4 +0,0 @@ -#! /bin/bash - -# Scale up the GUI by 2 times for HiDPI screens -sed -i '/\[JavaOptions\]/a -Dsun.java2d.uiScale=2' /opt/maptool/lib/app/MapTool.cfg diff --git a/.local/bin/setup/setupmaptool b/.local/bin/setup/setupmaptool new file mode 100755 index 0000000..d0d12e5 --- /dev/null +++ b/.local/bin/setup/setupmaptool @@ -0,0 +1,8 @@ +#! /bin/bash + +# Scale up the GUI by 2 times for HiDPI screens +if [ -f "${XDG_CONFIG_HOME:-$HOME/.config}/x11/.DPI" ]; then + DPI="$(cat "${XDG_CONFIG_HOME:-$HOME/.config}/x11/.DPI")" + SCALE="$(((DPI+48)/96))" + sudo -A sed -i "/\[JavaOptions\]/a -Dsun.java2d.uiScale=$SCALE" /opt/maptool/lib/app/MapTool.cfg +fi diff --git a/.local/bin/setup/nextcloud b/.local/bin/setup/setupnextcloud similarity index 100% rename from .local/bin/setup/nextcloud rename to .local/bin/setup/setupnextcloud diff --git a/.local/bin/setup/ssh b/.local/bin/setup/setupssh similarity index 100% rename from .local/bin/setup/ssh rename to .local/bin/setup/setupssh diff --git a/.local/bin/setup/wacom b/.local/bin/setup/setupwacom similarity index 100% rename from .local/bin/setup/wacom rename to .local/bin/setup/setupwacom diff --git a/.local/bin/sysact b/.local/bin/sysact index 5e3acf5..d3cdba8 100755 --- a/.local/bin/sysact +++ b/.local/bin/sysact @@ -8,14 +8,14 @@ case "$(readlink -f /sbin/init)" in *openrc*) reb="sudo -A openrc-shutdown -r"; shut="sudo -A openrc-shutdown -p 0" ;; esac + cmds="\ -🔒 lock slock -🚪 leave dwm kill -TERM $(pgrep -u $USER "\bdwm$") -♻ renew dwm kill -HUP $(pgrep -u $USER "\bdwm$") -🐻 hibernate slock ${hib:-systemctl suspend-then-hibernate -i} -🔃 reboot ${reb:-sudo -A reboot} -🖥 shutdown ${shut:-sudo -A shutdown -h now} -📺 display off xset dpms force off" + lock slock + leave dwm dwmc quit + renew dwm dwmc restart + hibernate slock ${hib:-systemctl suspend-then-hibernate -i} + reboot ${reb:-sudo -A reboot} + shutdown ${shut:-sudo -A shutdown -h now}" choice="$(echo "$cmds" | cut -d' ' -f 1 | dmenu)" || exit 1