this works fine running it from an xterm with dwm already running. mixerctl, apm, and date output all show up as expected.
Code:
xsetroot -name "volume: $(mixerctl -n outputs.master | sed 's/^[0-9]*,//g') | battery: $(apm -l)% | $(date "+%A, %B %e, %Y %r")"
however, if I put the same command in my .xsession file, the apm output disappears and all I see is "battery: %".
Code:
while true
do
xsetroot -name "volume: $(mixerctl -n outputs.master | sed 's/^[0-9]*,//g') | battery: $(apm -l)% | $(date "+%A, %B %e, %Y %r")"
done &
xbindkeys &
dwm
I can't figure out why the output of apm would disappear or be blank like that. maybe it has something to do with the environment that the .xsession script is run in or something. that's all I can think of. does anyone have any ideas?
I found this thread from the dwm mailing lists but it wasn't much help:
http://www.mail-archive.com/dwm@suck.../msg02452.html