wire-framework 0.1.4.26 → 0.1.5

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/lib/wire.rb CHANGED
@@ -1,28 +1,40 @@
1
- $environment = {} unless $environment
1
+ ##
2
+ # Copyright 2017 Bryan T. Meyers
3
+ #
4
+ # Licensed under the Apache License, Version 2.0 (the "License");
5
+ # you may not use this file except in compliance with the License.
6
+ # You may obtain a copy of the License at
7
+ #
8
+ # http://www.apache.org/licenses/LICENSE-2.0
9
+ #
10
+ # Unless required by applicable law or agreed to in writing, software
11
+ # distributed under the License is distributed on an "AS IS" BASIS,
12
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ # See the License for the specific language governing permissions and
14
+ # limitations under the License.
15
+ ##
2
16
 
3
- require_relative 'closet'
4
- require_relative 'app'
5
-
6
- require 'docile'
7
17
  require 'json'
8
- require 'rack'
9
18
 
10
19
  # The Ruby-Core JSON module
11
20
  module JSON
12
21
 
13
- # Force JSON.parse to symbolize names
14
- # @param [String] source the raw JSON string
15
- # @param [Hash] opts any further options for JSON.parse
16
- # @return [Hash] the parsed JSON content
17
- def self.parse_clean(source, opts = {})
18
- opts[:symbolize_names] = true
19
- parse(source, opts)
20
- end
22
+ # Force JSON.parse to symbolize names
23
+ # @param [String] source the raw JSON string
24
+ # @param [Hash] opts any further options for JSON.parse
25
+ # @return [Hash] the parsed JSON content
26
+ def self.parse_clean(source, opts = {})
27
+ opts[:symbolize_names] = true
28
+ parse(source, opts)
29
+ end
21
30
  end
22
31
 
23
32
  # Wire is an environment for quickly building REST services
24
33
  # @author Bryan T. Meyers
25
34
  module Wire
26
- # Current version of the Wire Gem
27
- VERSION = '0.1.4.26'
35
+ # Current version of the Wire Gem
36
+ VERSION = '0.1.5'
28
37
  end
38
+
39
+ require_relative 'app'
40
+ require_relative 'closet'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: wire-framework
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4.26
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bryan T. Meyers
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-08-13 00:00:00.000000000 Z
11
+ date: 2017-01-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: awesome_print
@@ -38,34 +38,6 @@ dependencies:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
- - !ruby/object:Gem::Dependency
42
- name: data_mapper
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - ">="
46
- - !ruby/object:Gem::Version
47
- version: '0'
48
- type: :runtime
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - ">="
53
- - !ruby/object:Gem::Version
54
- version: '0'
55
- - !ruby/object:Gem::Dependency
56
- name: docile
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - ">="
60
- - !ruby/object:Gem::Version
61
- version: '0'
62
- type: :runtime
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - ">="
67
- - !ruby/object:Gem::Version
68
- version: '0'
69
41
  - !ruby/object:Gem::Dependency
70
42
  name: lmdb
71
43
  requirement: !ruby/object:Gem::Requirement
@@ -109,7 +81,7 @@ dependencies:
109
81
  - !ruby/object:Gem::Version
110
82
  version: '0'
111
83
  - !ruby/object:Gem::Dependency
112
- name: rack
84
+ name: sequel
113
85
  requirement: !ruby/object:Gem::Requirement
114
86
  requirements:
115
87
  - - ">="
@@ -123,7 +95,7 @@ dependencies:
123
95
  - !ruby/object:Gem::Version
124
96
  version: '0'
125
97
  - !ruby/object:Gem::Dependency
126
- name: rest-less
98
+ name: rack
127
99
  requirement: !ruby/object:Gem::Requirement
128
100
  requirements:
129
101
  - - ">="
@@ -137,7 +109,7 @@ dependencies:
137
109
  - !ruby/object:Gem::Version
138
110
  version: '0'
139
111
  - !ruby/object:Gem::Dependency
140
- name: tilt
112
+ name: rest-less
141
113
  requirement: !ruby/object:Gem::Requirement
142
114
  requirements:
143
115
  - - ">="
@@ -151,7 +123,7 @@ dependencies:
151
123
  - !ruby/object:Gem::Version
152
124
  version: '0'
153
125
  - !ruby/object:Gem::Dependency
154
- name: wiki-this
126
+ name: tilt
155
127
  requirement: !ruby/object:Gem::Requirement
156
128
  requirements:
157
129
  - - ">="
@@ -164,8 +136,8 @@ dependencies:
164
136
  - - ">="
165
137
  - !ruby/object:Gem::Version
166
138
  version: '0'
167
- description: Wire is a DSL and Rack interface for quickly building web applications,
168
- without the needless complexity of Rails
139
+ description: Wire is a Rack interface for quickly building web applications, without
140
+ the needless complexity of Rails
169
141
  email: bmeyers@datadrake.com
170
142
  executables: []
171
143
  extensions: []
@@ -192,13 +164,13 @@ files:
192
164
  - lib/app/repo/svn.rb
193
165
  - lib/closet.rb
194
166
  - lib/closet/auth.rb
167
+ - lib/closet/config.rb
195
168
  - lib/closet/context.rb
196
169
  - lib/closet/renderer.rb
197
- - lib/closet/resource.rb
198
170
  - lib/wire.rb
199
171
  homepage: http://rubygems.org/gems/wire
200
172
  licenses:
201
- - GPL v2
173
+ - Apache-2.0
202
174
  metadata: {}
203
175
  post_install_message:
204
176
  rdoc_options: []
@@ -216,9 +188,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
216
188
  version: '0'
217
189
  requirements: []
218
190
  rubyforge_project:
219
- rubygems_version: 2.2.5
191
+ rubygems_version: 2.4.5.2
220
192
  signing_key:
221
193
  specification_version: 4
222
194
  summary: Wire Framework
223
195
  test_files: []
224
- has_rdoc:
@@ -1,20 +0,0 @@
1
- module Wire
2
-
3
- # Resource is a DSL function for mapping sub-URI in Wire::App(s)
4
- # @author Bryan T. Meyers
5
- module Resource
6
-
7
- # Setup a Renderer
8
- # @param [String] uri the sub-URI
9
- # @param [Proc] block for configuring this resource
10
- # @return [void]
11
- def resource(uri, &block)
12
- $current_app[:resources][uri] = {}
13
- $current_resource = $current_app[:resources][uri]
14
- if ENV['RACK_ENV'].eql? 'development'
15
- $stderr.puts "Starting Resource At: /#{$current_uri + '/' + uri}"
16
- end
17
- Docile.dsl_eval(self, &block)
18
- end
19
- end
20
- end