Sha256: 7a1fb0ad42e6aa2b113b77702ff144131daa54eb4b74bc0f2ac586b3d045cfdc
Contents?: true
Size: 268 Bytes
Versions: 33
Compression:
Stored size: 268 Bytes
Contents
class Dir # http://www.ruby-forum.com/topic/84762 def empty? Dir.glob("#{ path }/*", File::FNM_DOTMATCH) do |e| return false unless %w( . .. ).include?(File::basename(e)) end return true end def self.empty? path new(path).empty? end end
Version data entries
33 entries across 33 versions & 1 rubygems