Sha256: e412001e769ad2ba3b49bb6a8cabc28621526f12ab5d800854a2c574075ccbc6
Contents?: true
Size: 459 Bytes
Versions: 26
Compression:
Stored size: 459 Bytes
Contents
module Ftpd # Create temporary directories that will be removed when the program # exits. module TempDir # Create a temporary directory, returning its path. When the # program exists, the directory (and its contents) are removed. def make Dir.mktmpdir.tap do |path| at_exit do FileUtils.rm_rf path Dir.rmdir path if File.exists?(path) end end end module_function :make end end
Version data entries
26 entries across 26 versions & 2 rubygems