Files
2017-05-22 16:16:49 -05:00

25 lines
387 B
Tcl

#!/usr/local/bin/tclsh
foreach source $argv {
set target [file rootname $source].tt
set src [open $source RDONLY]
set tgt [open $target {RDWR CREAT TRUNC}]
while {[eof $src] == 0} {
set line [string trim [gets $src]]
if {$line == ""} {
continue
}
if {[string index $line 0] == "#"} {
continue
}
puts $tgt $line
}
close $src
close $tgt
}