six-updater-web 0.24.9 → 0.24.10
Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile
CHANGED
@@ -31,7 +31,7 @@ class Mod < ActiveRecord::Base
|
|
31
31
|
end
|
32
32
|
|
33
33
|
def process(setting, reset, autoskip, force = false)
|
34
|
-
self.update_version(setting
|
34
|
+
self.update_version(setting) # TODO: this already runs in updater_yml, but there doesn't run if autoskip is disabled
|
35
35
|
if reset && !autoskip
|
36
36
|
self.skip = false
|
37
37
|
else
|
@@ -55,7 +55,7 @@ class Mod < ActiveRecord::Base
|
|
55
55
|
#File.open('test.tar', 'wb') { |tar| Archive::Tar::Minitar.pack('tests', tar) }
|
56
56
|
# Unpacks 'test.tar' to 'x', creating 'x' if necessary.
|
57
57
|
# Archive::Tar::Minitar.unpack('test.tar', 'x')
|
58
|
-
rpath = self.real_path
|
58
|
+
rpath = self.real_path(setting)
|
59
59
|
|
60
60
|
path = File.join(rpath, 'store', 'userconfig.tar')
|
61
61
|
path = File.join(rpath, 'store', 'userconfig') unless File.exists?(path)
|
@@ -153,21 +153,22 @@ class Mod < ActiveRecord::Base
|
|
153
153
|
"mods/show"
|
154
154
|
end
|
155
155
|
|
156
|
-
def read_version(
|
157
|
-
|
158
|
-
|
156
|
+
def read_version(setting)
|
157
|
+
path = self.my_path(setting)
|
158
|
+
return unless path
|
159
|
+
cfg = File.join(path, '.rsync', '.repository.yml')
|
159
160
|
return nil unless File.exists?(cfg)
|
160
161
|
conf = YAML::load_file(cfg)
|
161
162
|
return nil unless conf
|
162
163
|
begin; conf[:version]; rescue; nil; end
|
163
164
|
end
|
164
165
|
|
165
|
-
def update_version(
|
166
|
-
self.version_local = self.read_version(
|
166
|
+
def update_version(setting)
|
167
|
+
self.version_local = self.read_version(setting).to_s
|
167
168
|
end
|
168
169
|
|
169
|
-
def update_skip_by_version(
|
170
|
-
self.update_version(
|
170
|
+
def update_skip_by_version(setting)
|
171
|
+
self.update_version(setting)
|
171
172
|
self.update_skip
|
172
173
|
end
|
173
174
|
|
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 0
|
7
7
|
- 24
|
8
|
-
-
|
9
|
-
version: 0.24.
|
8
|
+
- 10
|
9
|
+
version: 0.24.10
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Sickboy
|
@@ -14,7 +14,7 @@ autorequire:
|
|
14
14
|
bindir: bin
|
15
15
|
cert_chain: []
|
16
16
|
|
17
|
-
date: 2010-12-
|
17
|
+
date: 2010-12-31 00:00:00 +01:00
|
18
18
|
default_executable:
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|