Sha256: c7413405bd55acee98e1b63c58490c25d764bc05deeb36e453099056724a094f
Contents?: true
Size: 527 Bytes
Versions: 13
Compression:
Stored size: 527 Bytes
Contents
class String def to_entry_on driver = nil path = self driver ||= Vfs.default_driver path = "./#{path}" unless path =~ /^[\/\.\~]/ Vfs::Entry.new(driver, path).entry end alias_method :to_entry, :to_entry_on def to_file_on driver = nil to_entry_on(driver).file end alias_method :to_file, :to_file_on def to_dir_on driver = nil to_entry_on(driver).dir end alias_method :to_dir, :to_dir_on end class File def to_entry path.to_entry end def to_file path.to_file end end
Version data entries
13 entries across 13 versions & 3 rubygems