aerial 0.1.2 → 0.1.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/aerial.gemspec +1 -1
- data/lib/aerial.rb +6 -12
- metadata +2 -1
data/aerial.gemspec
CHANGED
data/lib/aerial.rb
CHANGED
@@ -34,19 +34,13 @@ module Aerial
|
|
34
34
|
@root ||= root
|
35
35
|
@logger ||= ::Logger.new(STDOUT)
|
36
36
|
@debug ||= false
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
config
|
41
|
-
|
42
|
-
|
43
|
-
elsif config.is_a?(Hash)
|
44
|
-
@config = Aerial::Config.new(config)
|
45
|
-
end
|
46
|
-
rescue Exception => e
|
47
|
-
# TODO: Display an error
|
37
|
+
@repo ||= Grit::Repo.new(@root) rescue nil
|
38
|
+
config = File.join(root, config_name)
|
39
|
+
if config.is_a?(String) && File.file?(config)
|
40
|
+
@config = Aerial::Config.new(YAML.load_file(config))
|
41
|
+
elsif config.is_a?(Hash)
|
42
|
+
@config = Aerial::Config.new(config)
|
48
43
|
end
|
49
|
-
|
50
44
|
end
|
51
45
|
|
52
46
|
def self.log(str)
|