static_sync 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/static_sync/config.rb +8 -2
- data/lib/static_sync/version.rb +1 -1
- metadata +1 -1
data/lib/static_sync/config.rb
CHANGED
@@ -33,11 +33,17 @@ module StaticSync
|
|
33
33
|
end
|
34
34
|
|
35
35
|
def gzip
|
36
|
-
self
|
36
|
+
self.fetch('gzip', true)
|
37
37
|
end
|
38
38
|
|
39
39
|
def load(path = '.static')
|
40
|
-
|
40
|
+
content = '{}'
|
41
|
+
begin
|
42
|
+
content = File.read(path)
|
43
|
+
rescue
|
44
|
+
# Loading config from file is not mandatory.
|
45
|
+
end
|
46
|
+
self.replace(YAML.load(ERB.new(content).result))
|
41
47
|
self
|
42
48
|
end
|
43
49
|
|
data/lib/static_sync/version.rb
CHANGED