Somebar related setup updates

This commit is contained in:
Mahesh Asolkar 2023-03-19 13:02:51 -07:00
parent a530048c76
commit d4778fad0f
2 changed files with 18 additions and 11 deletions

View File

@ -7,7 +7,8 @@ echo "Entourage: Configuring ${NUM_DISPS} displays" >> $DWL_LOG_FILE
if [[ $NUM_DISPS > 1 ]]; then
# Dual screen
wlr-randr --output HDMI-A-1 --on --pos 0,0 --output eDP-1 --on --pos 0,1050
# wlr-randr --output HDMI-A-1 --on --pos 0,0 --output eDP-1 --on --pos 0,1050
wlr-randr --output HDMI-A-1 --on --pos 0,0 --output eDP-1 --on --pos 2560,0
else
# Single laptop screen
wlr-randr --output HDMI-A-1 --off --output eDP-1 --on --pos 0,0
@ -25,8 +26,9 @@ echo "DWL ready!" >> $DWL_LOG_FILE
echo "Entourage: " $DWL_TAGS_FILE >> $DWL_LOG_FILE
if [ -e /usr/local/bin/somebar ]; then
/usr/local/bin/somebar &
dbus-run-session /usr/local/bin/somebar > $XDG_RUNTIME_DIR/somebar.log &
(sleep 2 && conky -c ~/.conkyrc > $XDG_RUNTIME_DIR/somebar-0) &
echo "Entourage: Started somebar " >> $DWL_LOG_FILE
else
DISPLAYS=$(wlr-randr | perl -ne 'print "$1 " if /^([\w-]+)/')
DISP_NUM=$(expr 0)

View File

@ -36,20 +36,25 @@ conky.config = {
use_spacer = 'left',
}
--[[ For Somebar ]]
conky.text = [[
${if_existing /usr/local/bin/somebar}status${endif} \
💻 ${cpu}% | \
💾 ${memperc}% | \
${if_existing /sys/class/net/enp3s0/operstate up}🌐 ${addr enp3s0}${else}\
💻 ${cpu}% \
💾 ${memperc}% \
${if_existing /sys/class/net/enp3s0/operstate up}🌎 ${addr enp3s0}${else}\
${if_existing /sys/class/net/wlp4s0/operstate up}📶 ${addr wlp4s0}${else}\
${if_up eth0}🌐 ${addr eth0}${else}\
network down ${endif}${endif}${endif} | \
${execi 600 curl wttr.in/~45.54,-122.83?format="%c%t"} | \
🔊 ${execi 10 amixer get Master | tail -1 | sed 's/.*\[\([0-9]*%\)\].*/\1/'} | \
🔋 ${battery_percent}% | \
${time %Y %h %d %I:%M%p %Z}
${if_up eth0}🌎 ${addr eth0}${else}\
network down ${endif}${endif}${endif} \
${execi 600 curl wttr.in/~45.54,-122.83?format="%c%t"} \
🔊 ${execi 10 amixer get Master | tail -1 | sed 's/.*\[\([0-9]*%\)\].*/\1/'} \
🔋 ${battery_percent}% \
📅 ${time %Y %h %d} \
🕑 ${time %I:%M%p %Z}
]]
--[[
Reference
🌡 ${execi 600 weather fips4105192520 | grep Tempera | awk '{print $2}'}°F | \
${execi 1 cat /tmp/dwl.tags.out} | \
🌦 ${weather http://weather.noaa.gov/pub/data/observations/metar/stations/ KHIO temperature 10} | \