I/O


readLines: Read a file into a list of lines and close it
  [h]: file handle or name [io.input ()]
returns
  l: list of lines


writeLine: Write values adding a newline after each
  [h]: file handle [io.output ()]
  ...: values to write (as for write)


basename: POSIX basename
  @param path
returns
  base: base name


dirname: POSIX dirname
  @param path
returns
  dir: directory component


changeSuffix: Change the suffix of a filename
  from: suffix to change (".-" for any suffix)
  to: suffix to replace with
  name: file name to change
returns
  name_: file name with new suffix


addSuffix: Add a suffix to a filename if not already present
  suff: suffix to add
  name: file name to change
returns
  name_: file name with new suffix


pathSplit: split a path into components
Multiple separators are compressed into one; the current directory
becomes an empty list, while the root directory becomes {"/"}.
Trailing separators are ignored.
  path: path
returns
  @param: path1, ..., pathn: path components
FIXME: Compare with Perl's File::Spec::splitdir


pathConcat: concatenate path components into a path
Empty components are ignored; an empty list is taken to be the
current directory
  @param: path1, ..., pathn: path components
returns
  path: path
FIXME: Compare with Perl's File::Spec::catfile


shell: Perform a shell command and return its output
  c: command
returns
  o: output, or nil if error


processFiles: Process files specified on the command-line
If no files given, process io.stdin; in list of files, "-" means
io.stdin
  f: function to process files with
    name: the name of the file being read
    i: the number of the argument