rubyslippers 0.98 → 0.99
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/code/superant.com.rubyslippers/listgemrecord.rb +2 -2
- data/configuration/rubyslippersversion.cnf +1 -1
- data/extras/zip/ioextras.rb +114 -0
- data/extras/zip/stdrubyext.rb +111 -0
- data/extras/zip/tempfile_bugfixed.rb +195 -0
- data/extras/zip/zip.rb +1376 -0
- data/extras/zip/zipfilesystem.rb +558 -0
- data/extras/zip/ziprequire.rb +61 -0
- data/rwd_files/HowTo_RubySlippers.txt +3 -0
- metadata +8 -2
@@ -0,0 +1,61 @@
|
|
1
|
+
require 'zip/zip'
|
2
|
+
|
3
|
+
class ZipList
|
4
|
+
def initialize(zipFileList)
|
5
|
+
@zipFileList = zipFileList
|
6
|
+
end
|
7
|
+
|
8
|
+
def get_input_stream(entry, &aProc)
|
9
|
+
@zipFileList.each {
|
10
|
+
|zfName|
|
11
|
+
Zip::ZipFile.open(zfName) {
|
12
|
+
|zf|
|
13
|
+
begin
|
14
|
+
return zf.get_input_stream(entry, &aProc)
|
15
|
+
rescue Errno::ENOENT
|
16
|
+
end
|
17
|
+
}
|
18
|
+
}
|
19
|
+
raise Errno::ENOENT,
|
20
|
+
"No matching entry found in zip files '#{@zipFileList.join(', ')}' "+
|
21
|
+
" for '#{entry}'"
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
25
|
+
|
26
|
+
module Kernel
|
27
|
+
alias :oldRequire :require
|
28
|
+
|
29
|
+
def require(moduleName)
|
30
|
+
zip_require(moduleName) || oldRequire(moduleName)
|
31
|
+
end
|
32
|
+
|
33
|
+
def zip_require(moduleName)
|
34
|
+
return false if already_loaded?(moduleName)
|
35
|
+
get_resource(ensure_rb_extension(moduleName)) {
|
36
|
+
|zis|
|
37
|
+
eval(zis.read); $" << moduleName
|
38
|
+
}
|
39
|
+
return true
|
40
|
+
rescue Errno::ENOENT => ex
|
41
|
+
return false
|
42
|
+
end
|
43
|
+
|
44
|
+
def get_resource(resourceName, &aProc)
|
45
|
+
zl = ZipList.new($:.grep(/\.zip$/))
|
46
|
+
zl.get_input_stream(resourceName, &aProc)
|
47
|
+
end
|
48
|
+
|
49
|
+
def already_loaded?(moduleName)
|
50
|
+
moduleRE = Regexp.new("^"+moduleName+"(\.rb|\.so|\.dll|\.o)?$")
|
51
|
+
$".detect { |e| e =~ moduleRE } != nil
|
52
|
+
end
|
53
|
+
|
54
|
+
def ensure_rb_extension(aString)
|
55
|
+
aString.sub(/(\.rb)?$/i, ".rb")
|
56
|
+
end
|
57
|
+
end
|
58
|
+
|
59
|
+
# Copyright (C) 2002 Thomas Sondergaard
|
60
|
+
# rubyzip is free software; you can redistribute it and/or
|
61
|
+
# modify it under the terms of the ruby license.
|
@@ -157,6 +157,9 @@ http://www.erikveen.dds.nl/rubywebdialogs/index.html
|
|
157
157
|
Thanks, Steven Gibson
|
158
158
|
|
159
159
|
=Changelog
|
160
|
+
version 0.99
|
161
|
+
bug fix - "view gem" tab - name selection
|
162
|
+
|
160
163
|
version 0.98
|
161
164
|
updated for rwdtinker version 1.50
|
162
165
|
changed width of text fields with help from RubyWebDialogs author
|
metadata
CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.8.4
|
|
3
3
|
specification_version: 1
|
4
4
|
name: rubyslippers
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: "0.
|
7
|
-
date: 2005-02-
|
6
|
+
version: "0.99"
|
7
|
+
date: 2005-02-08
|
8
8
|
summary: RubySlippers is a GUI wrapper for RubyGems using RubyWebDialogs.
|
9
9
|
require_paths:
|
10
10
|
- "."
|
@@ -89,6 +89,12 @@ files:
|
|
89
89
|
- configuration/tinkerwin2version.cnf
|
90
90
|
- configuration/rubyslippers.cnf
|
91
91
|
- configuration/rubyslippersversion.cnf
|
92
|
+
- extras/zip/ioextras.rb
|
93
|
+
- extras/zip/stdrubyext.rb
|
94
|
+
- extras/zip/tempfile_bugfixed.rb
|
95
|
+
- extras/zip/zip.rb
|
96
|
+
- extras/zip/zipfilesystem.rb
|
97
|
+
- extras/zip/ziprequire.rb
|
92
98
|
- ev/browser.rb
|
93
99
|
- ev/ftools.rb
|
94
100
|
- ev/net.rb
|