rack-rscript 1.1.3 → 1.1.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: e6bf34f921036c9bb60b380fb41e64280db27289
4
- data.tar.gz: 52f2d2b76ee05e29c1575d876b601c1ff2225a9f
2
+ SHA256:
3
+ metadata.gz: cbd3eb663817e716b9659b6d9f363508eb0e4e4a348d1310d9fe9958eeb38bee
4
+ data.tar.gz: 886403ab31bc13ea31a522fb7aa4617b2e950f1c210f6298af70dbcc81fdbbf6
5
5
  SHA512:
6
- metadata.gz: a7a072f5034d81ab1ec3afeb2b803822f8c674f94784443e2fd068c6a85db5146c4363682619c8edbf07a200b796a8419eb89d22f9b519351031a6b80402f4bd
7
- data.tar.gz: d8913dcf856a2e1b08c2c04352cdcb95a70d2745b146771c547bdcfe4abc2d8934f0ce6d7ca23489170ef76b0155afdd4d39cca0b79956aef3ed2bc00c22d205
6
+ metadata.gz: dadc9a749503aa9c456aa00ef013004e3f8a941aee9d4e9e31bfa153df474817b1b503cd06f573671c8a689b7aa2487a0725ccdfaa36e0aab68ac25637df2939
7
+ data.tar.gz: 8ec1bf779f2f2367c6769f3bc1811f02a4f09f01061834bca853bbe9366e8a99499193a343f009526c4461e4cc17b28538f3fcf8b04789228bb8dde987625551
checksums.yaml.gz.sig CHANGED
Binary file
data.tar.gz.sig CHANGED
Binary file
data/lib/rack-rscript.rb CHANGED
@@ -223,29 +223,32 @@ class RackRscript
223
223
 
224
224
  end
225
225
 
226
- get /^(\/(?:#{@static.join('|')}).*)/ do |path|
226
+ if @static.any? then
227
+
228
+ get /^(\/(?:#{@static.join('|')}).*)/ do |path|
227
229
 
228
- puts 'path: ' + path.inspect if @debug
229
- filepath = File.join(@app_root, @root, path )
230
+ puts 'path: ' + path.inspect if @debug
231
+ filepath = File.join(@app_root, @root, path )
230
232
 
231
- if @log then
232
- @log.info 'DandelionS1/default_routes: ' +
233
- "root: %s path: %s" % [@root, path]
234
- end
233
+ if @log then
234
+ @log.info 'DandelionS1/default_routes: ' +
235
+ "root: %s path: %s" % [@root, path]
236
+ end
235
237
 
236
- if path.length < 1 or path[-1] == '/' then
237
- path += 'index.html'
238
- File.read filepath
239
- elsif File.directory? filepath then
240
- Redirect.new (path + '/')
241
- elsif File.exists? filepath then
238
+ if path.length < 1 or path[-1] == '/' then
239
+ path += 'index.html'
240
+ File.read filepath
241
+ elsif File.directory? filepath then
242
+ Redirect.new (path + '/')
243
+ elsif File.exists? filepath then
242
244
 
243
- content_type = @filetype[filepath[/\w+$/].to_sym]
244
- [File.read(filepath), content_type || 'text/plain']
245
- else
246
- 'oops, file ' + filepath + ' not found'
247
- end
245
+ content_type = @filetype[filepath[/\w+$/].to_sym]
246
+ [File.read(filepath), content_type || 'text/plain']
247
+ else
248
+ 'oops, file ' + filepath + ' not found'
249
+ end
248
250
 
251
+ end
249
252
  end
250
253
 
251
254
  get /^\/$/ do
@@ -258,9 +261,11 @@ class RackRscript
258
261
 
259
262
  def run_request(request)
260
263
 
261
- content, content_type, status_code = run_route(request,
262
- @env['REQUEST_METHOD'])
263
-
264
+ #@log.debug 'inside run_request: ' + request.inspect if @log
265
+ #@log.debug 'inside run_request @env: ' + @env.inspect if @log
266
+ method_type = @env ? @env['REQUEST_METHOD'] : 'GET'
267
+ content, content_type, status_code = run_route(request, method_type)
268
+ #@log.debug 'inside run_request' if @log
264
269
  if content.is_a? Redirect then
265
270
 
266
271
  redirectx = content
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rack-rscript
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.3
4
+ version: 1.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Robertson
@@ -10,28 +10,32 @@ bindir: bin
10
10
  cert_chain:
11
11
  - |
12
12
  -----BEGIN CERTIFICATE-----
13
- MIIDljCCAn6gAwIBAgIBATANBgkqhkiG9w0BAQUFADBIMRIwEAYDVQQDDAlnZ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DAdBgNVHQ4EFgQUVppLTAhY
26
+ p8gQCn2FsLsZ52/KZ6owJgYDVR0RBB8wHYEbZ2VtbWFzdGVyQGphbWVzcm9iZXJ0
27
+ c29uLmV1MCYGA1UdEgQfMB2BG2dlbW1hc3RlckBqYW1lc3JvYmVydHNvbi5ldTAN
28
+ BgkqhkiG9w0BAQsFAAOCAYEAAml/WLcI8fT+QulD8hoZsWuewuLVwJiv7ghzLxAF
29
+ RlvLTBDSv2I9R78e8vqy6inLhvAzlkKr3jfJjjRXg7GHVQytWW6E4k2EtTaYMMkt
30
+ eyfNULcMR/gOjGYYzYNUuw0391bBKpvzyIvdQv0mrgoI99B5rX66s4jg0JBQbgXe
31
+ mhaLptf1n9HgPbbJjpmRHj6mhbY0mAdUV8VyBfcboOnpQWDVKrRLJPNUUmFD4d/B
32
+ /SQsoWX60/1wMIk0So3A71ebCrcVBou0Rl/QUOLP3tXqUY6LSjYT9gpOHVLCNuPL
33
+ QJP3XTf2DGVCTbQsnweemWbEI0LwlViBpZmvxDHmgjb+/pm/nsWnTdnAIoYyTxoc
34
+ 5cO/O0IpbqcI7fY8cu2IktrIF2XwY1ZAewV6Yrxp36JYt131ajbs1/madpsZrFYa
35
+ lDqRilVLi+NZf/R9vR/vaL53GOmDC+VoywL5frfWXVSK1Zs1fF7RAMZDJeYF0A8W
36
+ arbgkVprfDCrZHsF1ZnCIvNO
33
37
  -----END CERTIFICATE-----
34
- date: 2018-07-23 00:00:00.000000000 Z
38
+ date: 2019-02-16 00:00:00.000000000 Z
35
39
  dependencies:
36
40
  - !ruby/object:Gem::Dependency
37
41
  name: rack
@@ -137,22 +141,22 @@ dependencies:
137
141
  name: json
138
142
  requirement: !ruby/object:Gem::Requirement
139
143
  requirements:
140
- - - "~>"
141
- - !ruby/object:Gem::Version
142
- version: '2.1'
143
144
  - - ">="
144
145
  - !ruby/object:Gem::Version
145
146
  version: 2.1.0
147
+ - - "~>"
148
+ - !ruby/object:Gem::Version
149
+ version: '2.1'
146
150
  type: :runtime
147
151
  prerelease: false
148
152
  version_requirements: !ruby/object:Gem::Requirement
149
153
  requirements:
150
- - - "~>"
151
- - !ruby/object:Gem::Version
152
- version: '2.1'
153
154
  - - ">="
154
155
  - !ruby/object:Gem::Version
155
156
  version: 2.1.0
157
+ - - "~>"
158
+ - !ruby/object:Gem::Version
159
+ version: '2.1'
156
160
  - !ruby/object:Gem::Dependency
157
161
  name: rexslt
158
162
  requirement: !ruby/object:Gem::Requirement
@@ -177,42 +181,42 @@ dependencies:
177
181
  name: rsc
178
182
  requirement: !ruby/object:Gem::Requirement
179
183
  requirements:
180
- - - "~>"
181
- - !ruby/object:Gem::Version
182
- version: '0.4'
183
184
  - - ">="
184
185
  - !ruby/object:Gem::Version
185
186
  version: 0.4.0
187
+ - - "~>"
188
+ - !ruby/object:Gem::Version
189
+ version: '0.4'
186
190
  type: :runtime
187
191
  prerelease: false
188
192
  version_requirements: !ruby/object:Gem::Requirement
189
193
  requirements:
190
- - - "~>"
191
- - !ruby/object:Gem::Version
192
- version: '0.4'
193
194
  - - ">="
194
195
  - !ruby/object:Gem::Version
195
196
  version: 0.4.0
197
+ - - "~>"
198
+ - !ruby/object:Gem::Version
199
+ version: '0.4'
196
200
  - !ruby/object:Gem::Dependency
197
201
  name: polyrex-links
198
202
  requirement: !ruby/object:Gem::Requirement
199
203
  requirements:
200
- - - "~>"
201
- - !ruby/object:Gem::Version
202
- version: '0.3'
203
204
  - - ">="
204
205
  - !ruby/object:Gem::Version
205
206
  version: 0.3.0
207
+ - - "~>"
208
+ - !ruby/object:Gem::Version
209
+ version: '0.3'
206
210
  type: :runtime
207
211
  prerelease: false
208
212
  version_requirements: !ruby/object:Gem::Requirement
209
213
  requirements:
210
- - - "~>"
211
- - !ruby/object:Gem::Version
212
- version: '0.3'
213
214
  - - ">="
214
215
  - !ruby/object:Gem::Version
215
216
  version: 0.3.0
217
+ - - "~>"
218
+ - !ruby/object:Gem::Version
219
+ version: '0.3'
216
220
  description:
217
221
  email: james@jamesrobertson.eu
218
222
  executables: []
@@ -239,8 +243,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
239
243
  - !ruby/object:Gem::Version
240
244
  version: '0'
241
245
  requirements: []
242
- rubyforge_project:
243
- rubygems_version: 2.6.13
246
+ rubygems_version: 3.0.1
244
247
  signing_key:
245
248
  specification_version: 4
246
249
  summary: Rack-Rscript is a light-weight alternative to Sinatra-Rscript.
metadata.gz.sig CHANGED
Binary file