Module: Piculet::Logger::ClientHelper
- Included in:
- Client, DSL::EC2::SecurityGroup::Permissions, EC2Wrapper::SecurityGroupCollection, EC2Wrapper::SecurityGroupCollection::SecurityGroup, EC2Wrapper::SecurityGroupCollection::SecurityGroup::PermissionCollection, EC2Wrapper::SecurityGroupCollection::SecurityGroup::PermissionCollection::Permission
- Defined in:
- lib/piculet/logger.rb
Instance Method Summary collapse
Instance Method Details
#log(level, message, color, log_id = nil) ⇒ Object
20 21 22 23 24 25 26 27 |
# File 'lib/piculet/logger.rb', line 20 def log(level, , color, log_id = nil) = "[#{level.to_s.upcase}] #{}" unless level == :info << ": #{log_id}" if log_id << ' (dry-run)' if @options && @options.dry_run logger = (@options && @options.logger) || Piculet::Logger.instance = .send(color) if color logger.send(level, ) end |