exceptional 2.0.11 → 2.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/bin/exceptional CHANGED
@@ -26,7 +26,7 @@ USAGE
26
26
  require "exceptional/integration/tester"
27
27
  Exceptional::Config.load('config/exceptional.yml')
28
28
  end
29
- unless Exceptional::Config.api_key.empty?
29
+ if Exceptional::Config.api_key
30
30
  Exceptional::Integration.test
31
31
  else
32
32
  puts 'API key not configured'
@@ -39,7 +39,7 @@ USAGE
39
39
  puts 'Missing required paramater <api-key>. Check your app configuration at http://getexceptional.com.'
40
40
  else
41
41
  if (defined?(RAILS_ROOT) && !File.file?('config/environment.rb'))
42
- puts "Run this command from the root of your rails application." and return
42
+ puts "Run this command from the root of your rails application." and exit
43
43
  else
44
44
  Dir.mkdir('config') unless File.exists?('config')
45
45
  end
@@ -61,4 +61,4 @@ USAGE
61
61
  puts line
62
62
  end
63
63
  puts "----------------------------------------------";
64
- end
64
+ end
@@ -1,5 +1,9 @@
1
+ require 'yaml'
2
+
1
3
  module Exceptional
2
4
  class Config
5
+ class ConfigurationException < StandardError; end
6
+
3
7
  class << self
4
8
  DEFAULTS = {
5
9
  :ssl => false,
@@ -16,7 +20,7 @@ module Exceptional
16
20
  def load(config_file=nil)
17
21
  if (config_file && File.file?(config_file))
18
22
  begin
19
- config = YAML::load(File.open(config_file))
23
+ config = YAML::load_file(config_file)
20
24
  env_config = config[application_environment] || {}
21
25
  @api_key = config['api-key'] || env_config['api-key']
22
26
 
@@ -10,7 +10,7 @@ module Exceptional
10
10
  unless Exceptional::Remote.error(Exceptional::ExceptionData.new(e, "Test Exception"))
11
11
  puts "Problem sending exception to Exceptional. Check your API key."
12
12
  else
13
- puts "Exception sent successfully."
13
+ puts "Test Exception sent. Please login to http://getexceptional.com to see it!"
14
14
  end
15
15
  end
16
16
  end
@@ -1,3 +1,3 @@
1
1
  module Exceptional
2
- VERSION = '2.0.11'
2
+ VERSION = '2.0.12'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: exceptional
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.11
4
+ version: 2.0.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Contrast
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2010-03-05 00:00:00 +00:00
12
+ date: 2010-03-29 00:00:00 +01:00
13
13
  default_executable:
14
14
  dependencies: []
15
15