Sha256: a355236754be816a22676ae632b477302d0de6a4d05663635f80530e2e3c7a2a
Contents?: true
Size: 604 Bytes
Versions: 3
Compression:
Stored size: 604 Bytes
Contents
require File.join(File.dirname(__FILE__), 'le', 'host') require 'logger' module Le def self.new(token, local=false) self.checkParams(token) host = Le::Host.new(token, local) logger = Logger.new(host) logger.level = Logger::DEBUG if host.respond_to?(:formatter) logger.formatter = host.formatter end logger end def self.checkParams(token) # Check if the key is valid UUID format if (token =~ /\A(urn:uuid:)?[\da-f]{8}-([\da-f]{4}-){3}[\da-f]{12}\z/i) == nil puts "\nLE: It appears the LOGENTRIES_TOKEN you entered is invalid!\n" end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
le-2.1.3 | ./lib/le.rb |
le-2.1.2 | ./lib/le.rb |
le-2.1.1 | ./lib/le.rb |