lib/vfs/entries/file.rb in vfs-0.2 vs lib/vfs/entries/file.rb in vfs-0.2.1

- old
+ new

@@ -190,7 +190,15 @@ require 'tilt' args.unshift Object.new if args.size == 1 and args.first.is_a?(Hash) Tilt::ERBTemplate.new(path).render *args end + + def basename + ::File.basename(name, File.extname(name)) + end + + def extension + ::File.extname(name).sub(/^\./, '') + end end end \ No newline at end of file