Skip to content

@TingoL /mwminit.sh
Created

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
MonsterWM init script
while read -t 60 -r wmout || true; do
unset up
unset music
up=[$(checkupdates | wc -l)]
music=[$(cmus.sh)]
if [[ $wmout =~ ^(([[:digit:]]+:)+[[:digit:]]+ ?)+$ ]]; then
unset r
read -ra desktops <<< "$wmout"
for desktop in "${desktops[@]}"; do
IFS=':' read -r d w m c u <<< "$desktop"
((c)) && fg="1" bg="0" lc="\u1 " rc=" \ur" i="${ms[$m]}" || fg="8" bg="0" lc=" " rc=" "
((w)) && ((! c)) && fg="1" bg="0" lc="\ur " rc=" \ur"
((u)) && fg="7" bg="0" lc="\u7 " rc=" \ur"
r+="\f$fg\b$bg$lc${ds[$d]}$rc\fr\br"
done
fi
printf "\\\l%s\\\r%s\n" "$r \r\f2\b0$music \f6\b0$up \f5\b0$i" "$(date "+\c\f3\b0 %I:%M") "
done < "$ff" | bar &
monsterwm > "$ff"
rm $ff
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.