From 1481c576e5cba5be6887ac661a31306203627e8e Mon Sep 17 00:00:00 2001 From: Derek Taylor Date: Mon, 29 Jan 2024 11:45:16 -0600 Subject: [PATCH] Minor edits. --- .config/qtile/autostart.sh | 46 ++------------------------------------ 1 file changed, 2 insertions(+), 44 deletions(-) diff --git a/.config/qtile/autostart.sh b/.config/qtile/autostart.sh index 8ccaf37..7d5f0d2 100755 --- a/.config/qtile/autostart.sh +++ b/.config/qtile/autostart.sh @@ -2,29 +2,6 @@ COLORSCHEME=DoomOne -### CHECKS IF VIRTUAL MACHINE ### -# If so, this sets an appropriate screen resolution. -# This is needed as part of DTOS. -if [[ $(systemd-detect-virt) = "none" ]]; then - echo "Not running in a Virtual Machine"; -elif xrandr | grep "1366x768"; then - xrandr -s 1366x768 || echo "Cannot set 1366x768 resolution."; -elif xrandr | grep "1920x1080"; then - xrandr -s 1920x1080 || echo "Cannot set 1920x1080 resolution."; -else echo "Could not set a resolution." -fi - -### FIX EMACS ELPACA SYMLINKS ### -# This runs the fix-elpaca-symlinks scripts which -# fixes all of the symlinks in .config/emacs/elpaca/build. -# This is needed as part of DTOS and is only run ONCE! -if [[ -f "$HOME/.config/fix-elpaca-symlinks/log" ]]; then - echo "fix-eplaca-symlinks has been run previously." -else - /usr/local/bin/fix-elpaca-symlinks - touch "$HOME/.config/fix-elpaca-symlinks/log" - echo "has-been-run: TRUE" > "$HOME/.config/fix-elpaca-symlinks/log" -fi ### AUTOSTART PROGRAMS ### lxsession & @@ -32,6 +9,8 @@ picom --daemon & /usr/bin/emacs --daemon & nm-applet & "$HOME"/.screenlayout/layout.sh & +sleep 1 +conky -c "$HOME"/.config/conky/qtile/01/"$COLORSCHEME".conf || echo "Couldn't start conky." ### UNCOMMENT ONLY ONE OF THE FOLLOWING THREE OPTIONS! ### # 1. Uncomment to restore last saved wallpaper @@ -40,24 +19,3 @@ xargs xwallpaper --stretch < ~/.cache/wall & # find /usr/share/backgrounds/dtos-backgrounds/ -type f | shuf -n 1 | xargs xwallpaper --stretch & # 3. Uncomment to set wallpaper with nitrogen # nitrogen --restore & - -### SETS CONKY STYLE BASED ON SCREEN RESOLUTION -# Checks screen resolution. If 1080p or higher, then we use '01' conky. -# If less than 1080p (laptops?), then we use the smaller '02' conky. -# You can also set these to values '03' and '04' if you want a fancier -# conky that displays lua rings and sensor information. -resolutionHeight=$(xrandr | grep "primary" | awk '{print $4}' | awk -F "+" '{print $1}' | awk -F 'x' '{print $2}') - -if [[ $resolutionHeight -ge 1080 ]]; then - killall conky || echo "Conky not running." - sleep 2 - conky -c "$HOME"/.config/conky/qtile/01/"$COLORSCHEME".conf || echo "Couldn't start conky." -elif [[ $resolutionHeight -lt 1080 ]]; then - killall conky || echo "Conky not running." - sleep 2 - conky -c "$HOME"/.config/conky/qtile/02/"$COLORSCHEME".conf || echo "Couldn't start conky." -else - killall conky || echo "Conky not running." - sleep 2 - conky -c "$HOME"/.config/conky/qtile/02/"$COLORSCHEME".conf || echo "Couldn't start conky." -fi