Posted to tcl by dkf at Thu Feb 25 11:03:31 GMT 2010view pretty

proc process {in} {
    return "processed results from $in go here"
}

while {[gets stdin line] >= 0} {
    puts stdout [process $line]
}
exit