Class: Registry::Tarball

Inherits:
Download show all
Defined in:
lib/radiant/extension/script.rb

Direct Known Subclasses

Bzip2, Gzip

Instance Attribute Summary

Attributes inherited from Installer

#name, #path, #url

Instance Method Summary collapse

Methods inherited from Download

#download, #initialize, #install

Methods inherited from Installer

#copy_to_vendor_extensions, #initialize, #install, #migrate, #update

Methods inherited from Action

#file_utils, #rake, #tasks_include?

Constructor Details

This class inherits a constructor from Registry::Download

Instance Method Details

#filenameObject



210
211
212
# File 'lib/radiant/extension/script.rb', line 210

def filename
  "#{self.name}.tar"
end

#unpackObject



214
215
216
217
218
# File 'lib/radiant/extension/script.rb', line 214

def unpack
  output = nil
  cd(Dir.tmpdir) { output = `tar xvf #{filename}` }
  self.path = File.join(Dir.tmpdir, output.split(/\n/).first.split('/').first)
end