Updated 2013-09-04 16:25:52 by pooryorick

2004-02-09 VI

A tcl script to print out who all have been replied to by your "vacation" program and the last time that a reply went to them. This is based on the simple berkeley VIDBM package elsewhere on this wiki. The NUL character is included as part of the key, which is why it needs to be trimmed out.
 load dbm.so
 dbm init /users/venksi/.vacation

 set k [dbm first]

 while {1} {
     set t [dbm fetch $k]
     binary scan $t I time
     puts "[clock format  $time -format %Y/%m/%d.%H:%M:%S] [string trim $k "\0"]"
     if [catch {set k [dbm next $k]}] break

 dbm close