zarchitect 1.7.0 → 1.7.2
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.
- checksums.yaml +4 -4
- data/lib/zarchitect/assets.rb +4 -1
- data/lib/zarchitect/config.rb +2 -2
- data/lib/zarchitect/file_manager.rb +4 -3
- data/lib/zarchitect.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9aa34b3381e8c7c34dc36062a92864e84a0e98db1c5ad21a0fc2e0c941c6eb43
|
|
4
|
+
data.tar.gz: 7aca9ff4c0b761fdcdc10a48a06684352f1ea7541a10a8299441e9e6839481db
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ddcd6a76992a79454ed31aee8998f0b97b1212a9322ed1053883985ae65c6b5c0b037630d6975d28b54166d6c7d30bd13cf085886c3a30cbc8c52db349b0c749
|
|
7
|
+
data.tar.gz: 26e342e8984e2cbc696ff6d3d1f7f228f191a7903bed77477b3881f85b31349fd5d2b0aa585a409f8062a7914eada020f30185536170dc402771c71ed7dcbd22
|
data/lib/zarchitect/assets.rb
CHANGED
|
@@ -8,8 +8,11 @@ class Assets < Zarchitect
|
|
|
8
8
|
end
|
|
9
9
|
|
|
10
10
|
def update
|
|
11
|
-
Dir
|
|
11
|
+
Dir.glob(File.join(@from, '**', '*'), File::FNM_DOTMATCH).reject do |fullpath|
|
|
12
12
|
path = fullpath[(@from.length)..-1]
|
|
13
|
+
next if path[-1] == '.'
|
|
14
|
+
next if path.include?('.sass-cache')
|
|
15
|
+
|
|
13
16
|
if path.include?(HTMLDIR)
|
|
14
17
|
realpath = path[1..-1]
|
|
15
18
|
else
|
data/lib/zarchitect/config.rb
CHANGED
|
@@ -205,8 +205,8 @@ class Config
|
|
|
205
205
|
|
|
206
206
|
def validate_zrconf
|
|
207
207
|
GPI.print "Validating #{@file}."
|
|
208
|
-
unless @hash.has_key?("
|
|
209
|
-
@hash["
|
|
208
|
+
unless @hash.has_key?("symlink_files")
|
|
209
|
+
@hash["symlink_files"] = true
|
|
210
210
|
end
|
|
211
211
|
unless @hash.has_key?("url")
|
|
212
212
|
GPI.print "config key [url] missing in _config/_zarchitect.yaml."
|
|
@@ -12,8 +12,9 @@ class FileManager < Zarchitect
|
|
|
12
12
|
|
|
13
13
|
def run
|
|
14
14
|
# iterate FROM
|
|
15
|
-
Dir
|
|
15
|
+
Dir.glob(File.join(@from, '**', '*'), File::FNM_DOTMATCH).reject do |fullpath|
|
|
16
16
|
path = fullpath[(@from.length)..-1]
|
|
17
|
+
next if path[-1] == '.'
|
|
17
18
|
realpath = File.join(@to, path) # path of new dir/symlink
|
|
18
19
|
|
|
19
20
|
# dir handling / create copies in TO
|
|
@@ -42,14 +43,14 @@ class FileManager < Zarchitect
|
|
|
42
43
|
# create symlink in _html/files to physical files _files (if process did
|
|
43
44
|
# not abort)
|
|
44
45
|
unless File.exist?(realpath)
|
|
45
|
-
if Zarchitect.conf.
|
|
46
|
+
if Zarchitect.conf.symlink_files
|
|
46
47
|
symlink(rrealpath, realpath)
|
|
47
48
|
else
|
|
48
49
|
copy(rrealpath, realpath)
|
|
49
50
|
end
|
|
50
51
|
else
|
|
51
52
|
if File.stat(rrealpath).mtime > File.stat(realpath).mtime
|
|
52
|
-
if Zarchitect.conf.
|
|
53
|
+
if Zarchitect.conf.symlink_files
|
|
53
54
|
symlink(rrealpath, realpath)
|
|
54
55
|
else
|
|
55
56
|
copy(rrealpath, realpath)
|
data/lib/zarchitect.rb
CHANGED