Sha256: cd939c0d32bf85ad70589fa0ed4ce85a9abfd4a5ec63d705dbd2b69a3ce11cc7
Contents?: true
Size: 884 Bytes
Versions: 2
Compression:
Stored size: 884 Bytes
Contents
#!/usr/bin/env ratch # generate tar gzip package require 'ratch/extra/stage' require 'ratch/extra/zip' # Create a Tar'd Gzip package. main 'pack/tgz' do status "Creating .tgz package" config = configuration['pack'] || {} config = config['tgz'] || {} package = package.clone package.update(config) store = config[:store] || 'pkg' templ = config[:template] name = package.stage_name(templ) stage = File.join(store, name) files = package.filelist stage(stage, files) if dryrun? status "tar -cxf #{name}.tgz" else file = nil cd(store) do file = tgz(name) end transfer(file, store) end end # Transfer package file to storage location. def transfer(file, store) # move to store, unless already there dest = File.join(store, File.basename(file)) dest = File.expand_path(dest) mv(file, store) unless file == dest end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
ratch-0.4.1 | lib/ratch/toolset/ruby/pack/tgz |
ratch-0.4.0 | lib/ratch/toolset/ruby/pack/tgz |