File: string2c.tcl

package info (click to toggle)
nam 1.15-11
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 29,532 kB
  • sloc: cpp: 17,346; tcl: 10,655; sh: 2,997; ansic: 1,253; makefile: 139; perl: 66
file content (6 lines) | stat: -rwxr-xr-x 183 bytes parent folder | download | duplicates (18)
1
2
3
4
5
6
# Define a C string variable of the name $name
#  and set its value to what can be read from stdin

set name [lindex $argv 0]
gets stdin version
puts "char $name\[\] = \"$version\";"