I stumbled over a forgotten script I once used before we had watch(1).
Somebody might find it amusing.  The point of the ho/ce/cd dance
instead of cl was to avoid flicker.

------------------->
#!/bin/ksh

# home, clear to end of line, clear to end of display
for i in ho ce cd; do
        eval "$i=\$(tput $i)"
done

tput clear
while true; do
        print -R -n "$ho"
        eval "$@" | while IFS= read line; do
                print -R "$line$ce"
        done
        print -R -n "$cd"
        sleep 30
done
<-------------------

-- 
Christian "naddy" Weisgerber                          [email protected]

Reply via email to