ncfoundry 4.9.3 → 4.9.4
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/VERSION +1 -1
- data/lib/cfoundry/zip.rb +4 -4
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4686f2814c8da63d4fc01db8a921d7461b88923e
|
|
4
|
+
data.tar.gz: 2c273e1062dfb344ed3fdca7aaa9aa3dfaa0a4c9
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8bc5ddcb232491237a184f745f6262758592c4f10b7afef7b95a52014a5ffd2c8aa1f3f6029cfc6f232cdbee526f73ca6e138b5b6059701513d180a686467e8a
|
|
7
|
+
data.tar.gz: 5f8ec3e04e2f72dc51c325a17d1b9915ca6bd14a97f8505f9223963ca3fb3eb6868168bb86a9cac13a5a0d61b7ead9bb9241afa40390c8cd6831d0c43e3d970e
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
4.9.
|
|
1
|
+
4.9.4
|
data/lib/cfoundry/zip.rb
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
require "zip
|
|
1
|
+
require "zip"
|
|
2
2
|
|
|
3
3
|
module CFoundry
|
|
4
4
|
# Generic Zpi API. Uses rubyzip underneath, but may be changed in the future
|
|
@@ -13,7 +13,7 @@ module CFoundry
|
|
|
13
13
|
# contents, recursively (not just top-level).
|
|
14
14
|
def entry_lines(file)
|
|
15
15
|
entries = []
|
|
16
|
-
::Zip::
|
|
16
|
+
::Zip::File.foreach(file) do |zentry|
|
|
17
17
|
entries << zentry
|
|
18
18
|
end
|
|
19
19
|
entries
|
|
@@ -21,7 +21,7 @@ module CFoundry
|
|
|
21
21
|
|
|
22
22
|
# Unpack a zip +file+ to directory +dest+.
|
|
23
23
|
def unpack(file, dest)
|
|
24
|
-
::Zip::
|
|
24
|
+
::Zip::File.foreach(file) do |zentry|
|
|
25
25
|
epath = "#{dest}/#{zentry}"
|
|
26
26
|
dirname = File.dirname(epath)
|
|
27
27
|
FileUtils.mkdir_p(dirname) unless File.exists?(dirname)
|
|
@@ -44,7 +44,7 @@ module CFoundry
|
|
|
44
44
|
files = files_to_pack(dir)
|
|
45
45
|
return false if files.empty?
|
|
46
46
|
|
|
47
|
-
::Zip::
|
|
47
|
+
::Zip::File.open(zipfile, true) do |zf|
|
|
48
48
|
files.each do |f|
|
|
49
49
|
zf.add(f.sub("#{dir}/",''), f)
|
|
50
50
|
end
|