sqlite/tool/tostr.tcl
drh 48cc9a31e1 Convert the tool/tostr.awk script into tool/tostr.tcl. Remove two obsolete
Makefiles.  Purge NAWK from the configure script and from unix makefiles.
There are still two uses of NAWK in Makefile.msc.

FossilOrigin-Name: 5b6775215327a89232f5059653747a18e83b8b4b
2015-10-07 12:36:42 +00:00

13 lines
243 B
Tcl

#!/usr/bin/tcl
#
# Convert input text into a C string
#
set in [open [lindex $argv 0] rb]
while {![eof $in]} {
set line [gets $in]
if {[eof $in]} break;
set x [string map "\\\\ \\\\\\\\ \\\" \\\\\"" $line]
puts "\"$x\\n\""
}
close $in