nutils 0.8.3 → 0.8.4
Sign up to get free protection for your applications and to get access to all the features.
@@ -3,7 +3,7 @@ module Nutils
|
|
3
3
|
|
4
4
|
# @author Arnau Siches
|
5
5
|
#
|
6
|
-
# @version 1.1.
|
6
|
+
# @version 1.1.1
|
7
7
|
#
|
8
8
|
# The +filesystem_customizable+ data source allows an array for source
|
9
9
|
# directories and for layout directories.
|
@@ -22,20 +22,22 @@ module Nutils
|
|
22
22
|
|
23
23
|
def setup
|
24
24
|
# Create directories
|
25
|
-
(
|
25
|
+
(@sources + @layouts).each { |dir| FileUtils.mkdir_p dir }
|
26
26
|
end
|
27
27
|
def items
|
28
|
-
|
28
|
+
@sources.map do |dir|
|
29
29
|
load_objects(dir, 'item', Nanoc3::Item)
|
30
30
|
end.flatten
|
31
31
|
end
|
32
32
|
def layouts
|
33
|
-
|
33
|
+
@layouts.map do |dir|
|
34
34
|
load_objects(dir, 'layout', Nanoc3::Layout)
|
35
35
|
end.flatten
|
36
36
|
end
|
37
37
|
|
38
38
|
def up
|
39
|
+
@sources = config[:source_dir] || ['content']
|
40
|
+
@layouts = config[:layout_dir] || ['layouts']
|
39
41
|
@dtstart = Time.now
|
40
42
|
end
|
41
43
|
def down
|
data/lib/nutils.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: nutils
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 55
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 8
|
9
|
-
-
|
10
|
-
version: 0.8.
|
9
|
+
- 4
|
10
|
+
version: 0.8.4
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Arnau Siches
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2011-
|
18
|
+
date: 2011-07-17 00:00:00 -04:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|