grape-transformations 0.0.1 → 0.0.2
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/lib/grape/generators/transformations/entity_generator.rb +2 -4
- data/lib/grape/generators/transformations/install_generator.rb +1 -3
- data/lib/grape/tasks/{grapi_tasks.rake → grape_transformations_tasks.rake} +0 -0
- data/lib/grape/transformations.rb +3 -0
- data/lib/grape/transformations/engine.rb +1 -1
- data/lib/grape/transformations/version.rb +1 -1
- data/spec/{grapi_spec.rb → grape_transformations_spec.rb} +0 -0
- data/spec/spec_helper.rb +1 -0
- data/spec/test_app/config/initializers/{grapi.rb → grape-transformations.rb} +0 -0
- data/spec/test_app/log/development.log +72 -0
- data/spec/test_app/tmp/cache/7F3/650/registered_entities +1 -1
- metadata +8 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0671afb517a8ce6d8dae407d88c912f008a15f01
|
4
|
+
data.tar.gz: 6911ef6f1f38de48d2879b4f162acbcfea151217
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f46e9e53f6c05f33b720b53d50dafdaede2d454ef73a07bccb603b69fcaa732971b597f0ea5f3fd814ee9ae2bfb74c9c19c3d7d27be09cb27856a8a449c84ebd
|
7
|
+
data.tar.gz: 8ee78295cbca8d05726947c0cd00df809da0473921be6bc0de712cd5e43aeab0a490cb51ea1e71525ddc6a2b696f8f5ed64acc238c238ae1730996c1de2d55be
|
@@ -1,11 +1,9 @@
|
|
1
|
-
require 'rails/generators/base'
|
2
|
-
|
3
1
|
module Grape
|
4
2
|
module Generators
|
5
3
|
module Transformations
|
6
|
-
class EntityGenerator < Rails::Generators::Base
|
4
|
+
class EntityGenerator < ::Rails::Generators::Base
|
7
5
|
|
8
|
-
desc <<-DESC
|
6
|
+
desc <<-DESC
|
9
7
|
Create inherited Grape::Entity entity in your app/api/.../entities folder. this
|
10
8
|
created entity will have related with grape-transformations naming conventions
|
11
9
|
|
File without changes
|
@@ -1,6 +1,9 @@
|
|
1
1
|
require 'grape/transformations/version'
|
2
2
|
require 'grape/transformations/loader'
|
3
3
|
require 'grape/transformations/base'
|
4
|
+
require 'rails/generators'
|
5
|
+
require 'grape/generators/transformations/entity_generator'
|
6
|
+
require 'grape/generators/transformations/install_generator'
|
4
7
|
require 'grape/transformations/engine' if defined?(Rails)
|
5
8
|
require 'grape'
|
6
9
|
require 'rails'
|
File without changes
|
data/spec/spec_helper.rb
CHANGED
File without changes
|
@@ -70,3 +70,75 @@ Started GET "/api/v1/users/0" for 127.0.0.1 at 2014-11-19 12:27:38 -0500
|
|
70
70
|
|
71
71
|
|
72
72
|
Started GET "/api/v1/users/compact/0" for 127.0.0.1 at 2014-11-19 12:27:38 -0500
|
73
|
+
|
74
|
+
|
75
|
+
Started GET "/api/v1/animals/foo" for 127.0.0.1 at 2014-11-19 12:40:27 -0500
|
76
|
+
|
77
|
+
|
78
|
+
Started GET "/api/v1/animals/bar/0" for 127.0.0.1 at 2014-11-19 12:40:27 -0500
|
79
|
+
|
80
|
+
|
81
|
+
Started GET "/api/v1/users" for 127.0.0.1 at 2014-11-19 12:40:27 -0500
|
82
|
+
|
83
|
+
|
84
|
+
Started GET "/api/v1/users/compact" for 127.0.0.1 at 2014-11-19 12:40:27 -0500
|
85
|
+
|
86
|
+
|
87
|
+
Started GET "/api/v1/users/0" for 127.0.0.1 at 2014-11-19 12:40:27 -0500
|
88
|
+
|
89
|
+
|
90
|
+
Started GET "/api/v1/users/compact/0" for 127.0.0.1 at 2014-11-19 12:40:27 -0500
|
91
|
+
|
92
|
+
|
93
|
+
Started GET "/api/v1/animals/foo" for 127.0.0.1 at 2014-11-19 12:45:24 -0500
|
94
|
+
|
95
|
+
|
96
|
+
Started GET "/api/v1/animals/bar/0" for 127.0.0.1 at 2014-11-19 12:45:25 -0500
|
97
|
+
|
98
|
+
|
99
|
+
Started GET "/api/v1/users" for 127.0.0.1 at 2014-11-19 12:45:25 -0500
|
100
|
+
|
101
|
+
|
102
|
+
Started GET "/api/v1/users/compact" for 127.0.0.1 at 2014-11-19 12:45:25 -0500
|
103
|
+
|
104
|
+
|
105
|
+
Started GET "/api/v1/users/0" for 127.0.0.1 at 2014-11-19 12:45:25 -0500
|
106
|
+
|
107
|
+
|
108
|
+
Started GET "/api/v1/users/compact/0" for 127.0.0.1 at 2014-11-19 12:45:25 -0500
|
109
|
+
|
110
|
+
|
111
|
+
Started GET "/api/v1/animals/foo" for 127.0.0.1 at 2014-11-19 13:12:04 -0500
|
112
|
+
|
113
|
+
|
114
|
+
Started GET "/api/v1/animals/bar/0" for 127.0.0.1 at 2014-11-19 13:12:04 -0500
|
115
|
+
|
116
|
+
|
117
|
+
Started GET "/api/v1/users" for 127.0.0.1 at 2014-11-19 13:12:04 -0500
|
118
|
+
|
119
|
+
|
120
|
+
Started GET "/api/v1/users/compact" for 127.0.0.1 at 2014-11-19 13:12:04 -0500
|
121
|
+
|
122
|
+
|
123
|
+
Started GET "/api/v1/users/0" for 127.0.0.1 at 2014-11-19 13:12:04 -0500
|
124
|
+
|
125
|
+
|
126
|
+
Started GET "/api/v1/users/compact/0" for 127.0.0.1 at 2014-11-19 13:12:04 -0500
|
127
|
+
|
128
|
+
|
129
|
+
Started GET "/api/v1/animals/foo" for 127.0.0.1 at 2014-11-19 15:46:12 -0500
|
130
|
+
|
131
|
+
|
132
|
+
Started GET "/api/v1/animals/bar/0" for 127.0.0.1 at 2014-11-19 15:46:13 -0500
|
133
|
+
|
134
|
+
|
135
|
+
Started GET "/api/v1/users" for 127.0.0.1 at 2014-11-19 15:46:13 -0500
|
136
|
+
|
137
|
+
|
138
|
+
Started GET "/api/v1/users/compact" for 127.0.0.1 at 2014-11-19 15:46:13 -0500
|
139
|
+
|
140
|
+
|
141
|
+
Started GET "/api/v1/users/0" for 127.0.0.1 at 2014-11-19 15:46:13 -0500
|
142
|
+
|
143
|
+
|
144
|
+
Started GET "/api/v1/users/compact/0" for 127.0.0.1 at 2014-11-19 15:46:13 -0500
|
@@ -1 +1 @@
|
|
1
|
-
o: ActiveSupport::Cache::Entry:@value{I" Food:ETI"TestApp::Entities::Food;TI" User;TI"&TestApp::Entities::Users::Default;T:@created_atf
|
1
|
+
o: ActiveSupport::Cache::Entry:@value{I" Food:ETI"TestApp::Entities::Food;TI" User;TI"&TestApp::Entities::Users::Default;T:@created_atf1416429972.351149:@expires_in0
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: grape-transformations
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Johan Tique
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2014-11-
|
12
|
+
date: 2014-11-20 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
@@ -257,7 +257,7 @@ files:
|
|
257
257
|
- lib/grape/generators/templates/grape-transformations.rb
|
258
258
|
- lib/grape/generators/transformations/entity_generator.rb
|
259
259
|
- lib/grape/generators/transformations/install_generator.rb
|
260
|
-
- lib/grape/tasks/
|
260
|
+
- lib/grape/tasks/grape_transformations_tasks.rake
|
261
261
|
- lib/grape/transformations.rb
|
262
262
|
- lib/grape/transformations/base.rb
|
263
263
|
- lib/grape/transformations/engine.rb
|
@@ -267,7 +267,7 @@ files:
|
|
267
267
|
- spec/api/user_spec.rb
|
268
268
|
- spec/generators/entity_generator_spec.rb
|
269
269
|
- spec/generators/install_generator_spec.rb
|
270
|
-
- spec/
|
270
|
+
- spec/grape_transformations_spec.rb
|
271
271
|
- spec/spec_helper.rb
|
272
272
|
- spec/test_app/README.rdoc
|
273
273
|
- spec/test_app/Rakefile
|
@@ -302,7 +302,7 @@ files:
|
|
302
302
|
- spec/test_app/config/initializers/backtrace_silencers.rb
|
303
303
|
- spec/test_app/config/initializers/cookies_serializer.rb
|
304
304
|
- spec/test_app/config/initializers/filter_parameter_logging.rb
|
305
|
-
- spec/test_app/config/initializers/
|
305
|
+
- spec/test_app/config/initializers/grape-transformations.rb
|
306
306
|
- spec/test_app/config/initializers/inflections.rb
|
307
307
|
- spec/test_app/config/initializers/mime_types.rb
|
308
308
|
- spec/test_app/config/initializers/session_store.rb
|
@@ -317,7 +317,7 @@ files:
|
|
317
317
|
- spec/test_app/public/500.html
|
318
318
|
- spec/test_app/public/favicon.ico
|
319
319
|
- spec/test_app/tmp/cache/7F3/650/registered_entities
|
320
|
-
homepage:
|
320
|
+
homepage: https://github.com/codescrum/grape-transformations
|
321
321
|
licenses:
|
322
322
|
- MIT
|
323
323
|
metadata: {}
|
@@ -347,7 +347,7 @@ test_files:
|
|
347
347
|
- spec/api/user_spec.rb
|
348
348
|
- spec/generators/entity_generator_spec.rb
|
349
349
|
- spec/generators/install_generator_spec.rb
|
350
|
-
- spec/
|
350
|
+
- spec/grape_transformations_spec.rb
|
351
351
|
- spec/spec_helper.rb
|
352
352
|
- spec/test_app/app/api/api.rb
|
353
353
|
- spec/test_app/app/api/test_app/entities/animals/compact.rb
|
@@ -379,7 +379,7 @@ test_files:
|
|
379
379
|
- spec/test_app/config/initializers/backtrace_silencers.rb
|
380
380
|
- spec/test_app/config/initializers/cookies_serializer.rb
|
381
381
|
- spec/test_app/config/initializers/filter_parameter_logging.rb
|
382
|
-
- spec/test_app/config/initializers/
|
382
|
+
- spec/test_app/config/initializers/grape-transformations.rb
|
383
383
|
- spec/test_app/config/initializers/inflections.rb
|
384
384
|
- spec/test_app/config/initializers/mime_types.rb
|
385
385
|
- spec/test_app/config/initializers/session_store.rb
|