Posted By

Phoenicia7 on 05/14/12


Versions (?)

Who likes this?

1 person have marked this snippet as a favorite


File Line List

 / Published in: TCL

  1. proc _fileLinesList {fn} {
  2. # Returns the lines of a given file as a list.
  3. set f [open $fn r]
  4. set t [read $f [file size $fn]]
  5. close $f
  6. return [split $t \n]
  7. }

Report this snippet  

You need to login to post a comment.