mirror of
https://github.com/puppetlabs/vmpooler.git
synced 2026-01-26 01:58:41 -05:00
Adding rudimentary logging
This commit is contained in:
parent
fe5f2dc28a
commit
5838315609
2 changed files with 23 additions and 4 deletions
13
lib/logger.rb
Executable file
13
lib/logger.rb
Executable file
|
|
@ -0,0 +1,13 @@
|
|||
require 'rubygems' unless defined?(Gem)
|
||||
|
||||
class Logger
|
||||
def initialize
|
||||
end
|
||||
|
||||
def log level, string
|
||||
time = Time.new
|
||||
stamp = time.strftime('%Y-%m-%d %H:%M:%S')
|
||||
puts "[#{stamp}] #{string}"
|
||||
end
|
||||
end
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue