bleetz 1.2 → 1.3

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.
Files changed (2) hide show
  1. data/lib/bleetz.rb +7 -3
  2. metadata +3 -3
@@ -1,10 +1,12 @@
1
1
  require 'rubygems'
2
2
  require 'net/ssh'
3
3
  require 'yaml'
4
+ require 'bleetz/conf.rb'
5
+ require 'bleetz/object.rb'
4
6
 
5
7
  class Bleetz
6
8
 
7
- VERSION = "1.2"
9
+ VERSION = "1.3"
8
10
 
9
11
  USAGE = <<-EOF
10
12
  Usage: bleetz [-c conf_file -h -l -s][[-t -v -c conf_file] action]
@@ -24,11 +26,13 @@ EOF
24
26
  begin
25
27
  if @file.nil?
26
28
  cnf = YAML::load(File.open("#{Dir.pwd}/.bleetz"))
27
- require 'bleetz/conf.rb'
28
- require 'bleetz/object.rb'
29
29
  @file = cnf[:config] || cnf['config']
30
30
  end
31
31
  load @file
32
+ rescue TypeError
33
+ abort "Didn't you make a mistake in .bleetz file ?"
34
+ rescue ArgumentError
35
+ abort "Did you configure attribute like this: 'attribute: <value>'"
32
36
  rescue Exception => e
33
37
  abort "Problem during configuration loading: #{e.message}"
34
38
  end
metadata CHANGED
@@ -1,12 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bleetz
3
3
  version: !ruby/object:Gem::Version
4
- hash: 11
4
+ hash: 9
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
- - 2
9
- version: "1.2"
8
+ - 3
9
+ version: "1.3"
10
10
  platform: ruby
11
11
  authors:
12
12
  - Thibaut Deloffre