def get_new_file_writer(file)
      if File.extname(file) == '.gz'
        Zlib::GzipWriter.new(File.new(file, 'wb'))
      else
        File.new(file, 'wb')
      end
    end
def get_new_file_writer(file)
      if File.extname(file) == '.gz'
        Zlib::GzipWriter.new(File.new(file, 'wb'))
      else
        File.new(file, 'wb')
      end
    end
Opens the file according to it's extension (gziped or uncompressed)

 === Parameters

 * <tt>file</tt> -- A path/file string.