glog 0.0.7 → 0.0.8

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/lib/glog/page.rb CHANGED
@@ -6,14 +6,14 @@ module Glog
6
6
  def self.root
7
7
  get(Glog.config['root'])
8
8
  end
9
-
9
+
10
10
  def render
11
11
  self.template == false ? super : wrap_with_template(super)
12
12
  end
13
-
13
+
14
14
  def path_with_parent
15
15
  File.join(parent, name)
16
16
  end
17
-
17
+
18
18
  end
19
- end
19
+ end
data/lib/glog/template.rb CHANGED
@@ -4,7 +4,7 @@ module Glog
4
4
  class Template
5
5
 
6
6
  include Haml
7
-
7
+
8
8
  attr_accessor :page, :locals, :template
9
9
 
10
10
  def self.wrap(page, locals = {})
@@ -51,6 +51,5 @@ module Glog
51
51
  def build_template_path(path)
52
52
  ["templates", path].flatten.join(File::SEPARATOR) + '.haml'
53
53
  end
54
-
55
54
  end
56
55
  end
data/lib/glog.rb CHANGED
@@ -11,19 +11,24 @@ module Glog
11
11
  @@env = nil
12
12
 
13
13
  def self.config
14
- @@config ||= YAML.load_file('glog.yaml')
14
+ if File.exist?('glog.yaml')
15
+ @@config ||= YAML.load_file('glog.yaml')
16
+ else
17
+ @@config = { 'root' => 'root' }
18
+ end
19
+ @@config
15
20
  end
16
-
21
+
17
22
  def self.config=(config)
18
23
  @@config = config
19
24
  end
20
-
25
+
21
26
  def self.env
22
27
  @@env
23
28
  end
24
-
29
+
25
30
  def self.env=(env)
26
31
  @@env = env
27
32
  end
28
33
 
29
- end
34
+ end
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 7
9
- version: 0.0.7
8
+ - 8
9
+ version: 0.0.8
10
10
  platform: ruby
11
11
  authors:
12
12
  - Antono Vasiljev
@@ -144,6 +144,6 @@ rubyforge_project:
144
144
  rubygems_version: 1.3.6
145
145
  signing_key:
146
146
  specification_version: 3
147
- summary: Git powered bogging/cms engine
147
+ summary: JADOF+Rack = bogging/cms engine
148
148
  test_files: []
149
149