diff options
author | stanton <stanton> | 1998-09-21 23:39:52 (GMT) |
---|---|---|
committer | stanton <stanton> | 1998-09-21 23:39:52 (GMT) |
commit | 494c2de3a748b449c69ce322a1a741f5a31fd4d5 (patch) | |
tree | c3ece48c0ae3f4ba54787e0e8e729b65752ef3f9 /tools/cvtEOL.tcl | |
parent | 7a698c0488d99c0af42022714638ae1ba2afaa49 (diff) | |
download | tcl-494c2de3a748b449c69ce322a1a741f5a31fd4d5.zip tcl-494c2de3a748b449c69ce322a1a741f5a31fd4d5.tar.gz tcl-494c2de3a748b449c69ce322a1a741f5a31fd4d5.tar.bz2 |
Added contents of Tcl 8.1a2
Diffstat (limited to 'tools/cvtEOL.tcl')
-rw-r--r-- | tools/cvtEOL.tcl | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/tools/cvtEOL.tcl b/tools/cvtEOL.tcl new file mode 100644 index 0000000..e2df341 --- /dev/null +++ b/tools/cvtEOL.tcl @@ -0,0 +1,35 @@ +# cvtEOL.tcl -- +# +# This file contains a script to parse a Tcl/Tk distribution and +# convert the EOL from \n to \r on all text files. +# +# Copyright (c) 1996-1997 by Sun Microsystems, Inc. +# +# SCCS: @(#) cvtEOL.tcl 1.1 97/01/30 11:33:33 +# + +# +# Convert files in the distribution to Mac style +# + +set distDir [lindex $argv 0] + +set dirs {unix mac generic win library compat tests unix/dltest \ + library/demos library/demos/images bitmaps xlib xlib/X11 .} +set files {*.c *.y *.h *.r *.tcl *.test *.rc *.bc *.vc *.bmp *.html \ + *.in *.notes *.terms all defs \ + README ToDo changes tclIndex configure install-sh mkLinks \ + square widget rmt ixset hello browse rolodex tcolor timer} + +foreach x $dirs { + if [catch {cd $distDir/$x}] continue + puts "Working on $x..." + foreach y [eval glob $files] { + exec chmod 666 $y + exec cp $y $y.tmp + exec tr \012 \015 < $y.tmp > $y + exec chmod 444 $y + exec rm $y.tmp + } +} + |