Module: ByteBoozer2
- Defined in:
- lib/byteboozer2.rb,
lib/byteboozer2/file.rb,
lib/byteboozer2/version.rb,
lib/byteboozer2/cruncher.rb
Overview
This module provides compression methods available in ByteBoozer 2.0.
Defined Under Namespace
Constant Summary collapse
- VERSION =
'0.0.5'
Class Method Summary collapse
Instance Method Summary collapse
- #crunch(file_name) ⇒ Object
- #ecrunch(file_name, address) ⇒ Object
- #rcrunch(file_name, address) ⇒ Object
Class Method Details
.log_level=(level) ⇒ Object
25 26 27 |
# File 'lib/byteboozer2.rb', line 25 def self.log_level=(level) logger.level = level end |
.logger ⇒ Object
18 19 20 21 22 23 |
# File 'lib/byteboozer2.rb', line 18 def self.logger @logger ||= Logger.new('byteboozer2.log').tap do |log| log.level = Logger::WARN log.progname = 'ByteBoozer2' end end |
Instance Method Details
#crunch(file_name) ⇒ Object
10 11 12 |
# File 'lib/byteboozer2.rb', line 10 def crunch(file_name) compress(file_name) end |
#ecrunch(file_name, address) ⇒ Object
14 15 16 |
# File 'lib/byteboozer2.rb', line 14 def ecrunch(file_name, address) compress(file_name, address:, executable: true) end |
#rcrunch(file_name, address) ⇒ Object
29 30 31 |
# File 'lib/byteboozer2.rb', line 29 def rcrunch(file_name, address) compress(file_name, address:, relocated: true) end |