Sha256: d32b1563b83fd7caae16e9454021d61130b7ed275ccf236af452a0e654f94fd8
Contents?: true
Size: 425 Bytes
Versions: 21
Compression:
Stored size: 425 Bytes
Contents
# == Synopsis # add a mkdirs method to the File class class File class << self my_extension("mkdirs") do ## # make directories including any missing in the path # # @param [String] dirspec the path to make sure exists def File.mkdirs(dirspec) unless File.exists?(dirspec) mkdirs(File.dirname(dirspec)) Dir.mkdir(dirspec) end end end end end
Version data entries
21 entries across 21 versions & 5 rubygems