Class: File

Inherits:
Object
  • Object
show all
Defined in:
lib/rscale/helpers.rb

Class Method Summary collapse

Class Method Details

.get_info(path) ⇒ Object



38
39
40
41
42
# File 'lib/rscale/helpers.rb', line 38

def self.get_info(path)
  ext = File.extname(path) ; ext = ext[1..(ext.length-1)]
  name = File.basename(path, File.extname(path))
  return {:filename => name, :extension => ext, :filesize => File.size(path)}
end