ref: 1fd6a3738a4775ee3a326a31a750778c1d0ddda1
dir: /r/
#!/bin/rc
# 2025-10-17T19:59:34-04:00
# bof: http://shithub.us/qwx/fork/HEAD/info.html
# rio.themes: https://ftrv.se/14
# copy this file to $home/bin/rc and modify to suit.
# use with: http://plan9.stanleylieber.com/rc/tobit
. /$cputype/mkfile
scr=(`{cat /dev/draw/new >[2]/dev/null})
w=$scr(11)
h=$scr(12)
switch($w){
case 28*
font=/lib/font/contrib.bit/hugevga/unicode.font
case 21* 22* 25*
font=/lib/font/bit/lucidasans/unicode.10.font
case *
font=/lib/font/bit/vga/unicode.font
}
truetypefs
riocmd=(rio.themes)
switch($*){
case -b
riocmd=(bof)
bind $home/lib/rio.theme.black $home/lib/rio.theme
case -t
bind $home/lib/rio.theme.orig $home/lib/rio.theme
case -ta
bind $home/lib/rio.theme.amber $home/lib/rio.theme
case -tbw
bind $home/lib/rio.theme.bw $home/lib/rio.theme
case -tf
bind $home/lib/rio.theme.fairlight $home/lib/rio.theme
case -tg
bind $home/lib/rio.theme.green $home/lib/rio.theme
case -tm
bind $home/lib/rio.theme.matrix $home/lib/rio.theme
case -tmb
bind $home/lib/rio.theme.black $home/lib/rio.theme
case -tr
bind $home/lib/rio.theme.tron $home/lib/rio.theme
case -ts
bind $home/lib/rio.theme.sigrid $home/lib/rio.theme
case -tw
bind $home/lib/rio.theme.white $home/lib/rio.theme
case *
riocmd=(rio)
exec $riocmd -i $home/lib/riostart
}
if(~ $riocmd rio.themes){
riob=`{basename `{fortune <{hget http://bg.stanleylieber.com/index}}}
ramfs -m /n/bg &&
hget http://bg.stanleylieber.com/img/bg/$riob >/n/bg/$riob &&
tobit /n/bg/$riob >/n/bg/bg.img
}
if(~ $riocmd bof){
aux/stub /dev/theme
bind $home/lib/rio.theme /dev/theme
}
exec $riocmd -i $home/lib/riostart