gallery 0.0.11

Sign up to get free protection for your applications and to get access to all the features.
Files changed (102) hide show
  1. data/MIT-LICENSE +20 -0
  2. data/Rakefile +34 -0
  3. data/app/assets/javascripts/gallery/admin/admin.js +2 -0
  4. data/app/assets/javascripts/gallery/admin/albums.js +2 -0
  5. data/app/assets/javascripts/gallery/albums.js +2 -0
  6. data/app/assets/javascripts/gallery/application.js +13 -0
  7. data/app/assets/javascripts/gallery/gallery.js.coffee +229 -0
  8. data/app/assets/javascripts/gallery/images_loaded.js +6 -0
  9. data/app/assets/javascripts/gallery/omniauth_callbacks.js +2 -0
  10. data/app/assets/javascripts/gallery/photos.js +2 -0
  11. data/app/assets/javascripts/gallery/spinner.js +1 -0
  12. data/app/assets/stylesheets/gallery/admin/admin.css +4 -0
  13. data/app/assets/stylesheets/gallery/admin/albums.css +4 -0
  14. data/app/assets/stylesheets/gallery/albums.css +4 -0
  15. data/app/assets/stylesheets/gallery/application.css +13 -0
  16. data/app/assets/stylesheets/gallery/omniauth_callbacks.css +4 -0
  17. data/app/assets/stylesheets/gallery/photos.css +4 -0
  18. data/app/assets/stylesheets/gallery/style.css.scss +193 -0
  19. data/app/controllers/gallery/admin/admin_controller.rb +14 -0
  20. data/app/controllers/gallery/admin/albums_controller.rb +36 -0
  21. data/app/controllers/gallery/albums_controller.rb +9 -0
  22. data/app/controllers/gallery/application_controller.rb +4 -0
  23. data/app/controllers/gallery/omniauth_callbacks_controller.rb +27 -0
  24. data/app/controllers/gallery/photos_controller.rb +23 -0
  25. data/app/helpers/gallery/admin/admin_helper.rb +4 -0
  26. data/app/helpers/gallery/admin/albums_helper.rb +4 -0
  27. data/app/helpers/gallery/albums_helper.rb +4 -0
  28. data/app/helpers/gallery/application_helper.rb +4 -0
  29. data/app/helpers/gallery/omniauth_callbacks_helper.rb +4 -0
  30. data/app/helpers/gallery/photos_helper.rb +4 -0
  31. data/app/models/gallery/album.rb +66 -0
  32. data/app/models/gallery/identity.rb +43 -0
  33. data/app/models/gallery/photo.rb +14 -0
  34. data/app/views/gallery/admin/admin/index.html.erb +46 -0
  35. data/app/views/gallery/admin/albums/show.html.erb +14 -0
  36. data/app/views/gallery/albums/_admin_album_element.html.erb +18 -0
  37. data/app/views/gallery/albums/_album_element.html.erb +15 -0
  38. data/app/views/gallery/albums/index.html.erb +9 -0
  39. data/config/initializers/omniauth.rb +18 -0
  40. data/config/routes.rb +22 -0
  41. data/db/migrate/20130806170912_create_gallery_identities.rb +14 -0
  42. data/db/migrate/20130806212451_add_token_to_identity.rb +5 -0
  43. data/db/migrate/20130806213308_create_gallery_albums.rb +19 -0
  44. data/db/migrate/20130806214102_create_gallery_photos.rb +18 -0
  45. data/db/migrate/20130806221405_add_public_to_album.rb +5 -0
  46. data/db/migrate/20130806221438_add_public_to_photo.rb +5 -0
  47. data/db/migrate/20130807113616_add_thumbnail_to_photo.rb +6 -0
  48. data/lib/gallery.rb +4 -0
  49. data/lib/gallery/engine.rb +9 -0
  50. data/lib/gallery/version.rb +3 -0
  51. data/lib/tasks/gallery_tasks.rake +4 -0
  52. data/test/controllers/gallery/admin/admin_controller_test.rb +9 -0
  53. data/test/controllers/gallery/admin/albums_controller_test.rb +9 -0
  54. data/test/controllers/gallery/albums_controller_test.rb +9 -0
  55. data/test/controllers/gallery/omniauth_callbacks_controller_test.rb +9 -0
  56. data/test/controllers/gallery/photos_controller_test.rb +9 -0
  57. data/test/dummy/README.rdoc +28 -0
  58. data/test/dummy/Rakefile +6 -0
  59. data/test/dummy/app/assets/javascripts/application.js +13 -0
  60. data/test/dummy/app/assets/stylesheets/application.css +13 -0
  61. data/test/dummy/app/controllers/application_controller.rb +5 -0
  62. data/test/dummy/app/helpers/application_helper.rb +2 -0
  63. data/test/dummy/app/views/layouts/application.html.erb +14 -0
  64. data/test/dummy/bin/bundle +3 -0
  65. data/test/dummy/bin/rails +4 -0
  66. data/test/dummy/bin/rake +4 -0
  67. data/test/dummy/config.ru +4 -0
  68. data/test/dummy/config/application.rb +23 -0
  69. data/test/dummy/config/boot.rb +5 -0
  70. data/test/dummy/config/database.yml +25 -0
  71. data/test/dummy/config/environment.rb +5 -0
  72. data/test/dummy/config/environments/development.rb +29 -0
  73. data/test/dummy/config/environments/production.rb +80 -0
  74. data/test/dummy/config/environments/test.rb +36 -0
  75. data/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
  76. data/test/dummy/config/initializers/filter_parameter_logging.rb +4 -0
  77. data/test/dummy/config/initializers/inflections.rb +16 -0
  78. data/test/dummy/config/initializers/mime_types.rb +5 -0
  79. data/test/dummy/config/initializers/secret_token.rb +12 -0
  80. data/test/dummy/config/initializers/session_store.rb +3 -0
  81. data/test/dummy/config/initializers/wrap_parameters.rb +14 -0
  82. data/test/dummy/config/locales/en.yml +23 -0
  83. data/test/dummy/config/routes.rb +4 -0
  84. data/test/dummy/public/404.html +58 -0
  85. data/test/dummy/public/422.html +58 -0
  86. data/test/dummy/public/500.html +57 -0
  87. data/test/dummy/public/favicon.ico +0 -0
  88. data/test/fixtures/gallery/albums.yml +23 -0
  89. data/test/fixtures/gallery/identities.yml +13 -0
  90. data/test/fixtures/gallery/photos.yml +21 -0
  91. data/test/gallery_test.rb +7 -0
  92. data/test/helpers/gallery/admin/admin_helper_test.rb +6 -0
  93. data/test/helpers/gallery/admin/albums_helper_test.rb +6 -0
  94. data/test/helpers/gallery/albums_helper_test.rb +6 -0
  95. data/test/helpers/gallery/omniauth_callbacks_helper_test.rb +6 -0
  96. data/test/helpers/gallery/photos_helper_test.rb +6 -0
  97. data/test/integration/navigation_test.rb +10 -0
  98. data/test/models/gallery/album_test.rb +9 -0
  99. data/test/models/gallery/identity_test.rb +9 -0
  100. data/test/models/gallery/photo_test.rb +9 -0
  101. data/test/test_helper.rb +15 -0
  102. metadata +324 -0
@@ -0,0 +1,9 @@
1
+ require 'test_helper'
2
+
3
+ module Gallery
4
+ class AlbumTest < ActiveSupport::TestCase
5
+ # test "the truth" do
6
+ # assert true
7
+ # end
8
+ end
9
+ end
@@ -0,0 +1,9 @@
1
+ require 'test_helper'
2
+
3
+ module Gallery
4
+ class IdentityTest < ActiveSupport::TestCase
5
+ # test "the truth" do
6
+ # assert true
7
+ # end
8
+ end
9
+ end
@@ -0,0 +1,9 @@
1
+ require 'test_helper'
2
+
3
+ module Gallery
4
+ class PhotoTest < ActiveSupport::TestCase
5
+ # test "the truth" do
6
+ # assert true
7
+ # end
8
+ end
9
+ end
@@ -0,0 +1,15 @@
1
+ # Configure Rails Environment
2
+ ENV["RAILS_ENV"] = "test"
3
+
4
+ require File.expand_path("../dummy/config/environment.rb", __FILE__)
5
+ require "rails/test_help"
6
+
7
+ Rails.backtrace_cleaner.remove_silencers!
8
+
9
+ # Load support files
10
+ Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }
11
+
12
+ # Load fixtures from the engine
13
+ if ActiveSupport::TestCase.method_defined?(:fixture_path=)
14
+ ActiveSupport::TestCase.fixture_path = File.expand_path("../fixtures", __FILE__)
15
+ end
metadata ADDED
@@ -0,0 +1,324 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: gallery
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.11
5
+ prerelease:
6
+ platform: ruby
7
+ authors:
8
+ - Nam Chu Hoai
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2013-11-13 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: rails
16
+ requirement: !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ~>
20
+ - !ruby/object:Gem::Version
21
+ version: 4.0.0.rc1
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ~>
28
+ - !ruby/object:Gem::Version
29
+ version: 4.0.0.rc1
30
+ - !ruby/object:Gem::Dependency
31
+ name: omniauth
32
+ requirement: !ruby/object:Gem::Requirement
33
+ none: false
34
+ requirements:
35
+ - - ! '>='
36
+ - !ruby/object:Gem::Version
37
+ version: '0'
38
+ type: :runtime
39
+ prerelease: false
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ! '>='
44
+ - !ruby/object:Gem::Version
45
+ version: '0'
46
+ - !ruby/object:Gem::Dependency
47
+ name: omniauth-google-oauth2
48
+ requirement: !ruby/object:Gem::Requirement
49
+ none: false
50
+ requirements:
51
+ - - ! '>='
52
+ - !ruby/object:Gem::Version
53
+ version: '0'
54
+ type: :runtime
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ! '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ - !ruby/object:Gem::Dependency
63
+ name: omniauth-facebook
64
+ requirement: !ruby/object:Gem::Requirement
65
+ none: false
66
+ requirements:
67
+ - - ! '>='
68
+ - !ruby/object:Gem::Version
69
+ version: '0'
70
+ type: :runtime
71
+ prerelease: false
72
+ version_requirements: !ruby/object:Gem::Requirement
73
+ none: false
74
+ requirements:
75
+ - - ! '>='
76
+ - !ruby/object:Gem::Version
77
+ version: '0'
78
+ - !ruby/object:Gem::Dependency
79
+ name: sass-rails
80
+ requirement: !ruby/object:Gem::Requirement
81
+ none: false
82
+ requirements:
83
+ - - ! '>='
84
+ - !ruby/object:Gem::Version
85
+ version: '0'
86
+ type: :runtime
87
+ prerelease: false
88
+ version_requirements: !ruby/object:Gem::Requirement
89
+ none: false
90
+ requirements:
91
+ - - ! '>='
92
+ - !ruby/object:Gem::Version
93
+ version: '0'
94
+ - !ruby/object:Gem::Dependency
95
+ name: coffee-rails
96
+ requirement: !ruby/object:Gem::Requirement
97
+ none: false
98
+ requirements:
99
+ - - ! '>='
100
+ - !ruby/object:Gem::Version
101
+ version: '0'
102
+ type: :runtime
103
+ prerelease: false
104
+ version_requirements: !ruby/object:Gem::Requirement
105
+ none: false
106
+ requirements:
107
+ - - ! '>='
108
+ - !ruby/object:Gem::Version
109
+ version: '0'
110
+ - !ruby/object:Gem::Dependency
111
+ name: bourbon
112
+ requirement: !ruby/object:Gem::Requirement
113
+ none: false
114
+ requirements:
115
+ - - ! '>='
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ type: :runtime
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ none: false
122
+ requirements:
123
+ - - ! '>='
124
+ - !ruby/object:Gem::Version
125
+ version: '0'
126
+ - !ruby/object:Gem::Dependency
127
+ name: sqlite3
128
+ requirement: !ruby/object:Gem::Requirement
129
+ none: false
130
+ requirements:
131
+ - - ! '>='
132
+ - !ruby/object:Gem::Version
133
+ version: '0'
134
+ type: :development
135
+ prerelease: false
136
+ version_requirements: !ruby/object:Gem::Requirement
137
+ none: false
138
+ requirements:
139
+ - - ! '>='
140
+ - !ruby/object:Gem::Version
141
+ version: '0'
142
+ description: An easy gem to include a gallery to your site
143
+ email:
144
+ - nambrot@gmail.com
145
+ executables: []
146
+ extensions: []
147
+ extra_rdoc_files: []
148
+ files:
149
+ - app/assets/javascripts/gallery/admin/admin.js
150
+ - app/assets/javascripts/gallery/admin/albums.js
151
+ - app/assets/javascripts/gallery/albums.js
152
+ - app/assets/javascripts/gallery/application.js
153
+ - app/assets/javascripts/gallery/gallery.js.coffee
154
+ - app/assets/javascripts/gallery/images_loaded.js
155
+ - app/assets/javascripts/gallery/omniauth_callbacks.js
156
+ - app/assets/javascripts/gallery/photos.js
157
+ - app/assets/javascripts/gallery/spinner.js
158
+ - app/assets/stylesheets/gallery/admin/admin.css
159
+ - app/assets/stylesheets/gallery/admin/albums.css
160
+ - app/assets/stylesheets/gallery/albums.css
161
+ - app/assets/stylesheets/gallery/application.css
162
+ - app/assets/stylesheets/gallery/omniauth_callbacks.css
163
+ - app/assets/stylesheets/gallery/photos.css
164
+ - app/assets/stylesheets/gallery/style.css.scss
165
+ - app/controllers/gallery/admin/admin_controller.rb
166
+ - app/controllers/gallery/admin/albums_controller.rb
167
+ - app/controllers/gallery/albums_controller.rb
168
+ - app/controllers/gallery/application_controller.rb
169
+ - app/controllers/gallery/omniauth_callbacks_controller.rb
170
+ - app/controllers/gallery/photos_controller.rb
171
+ - app/helpers/gallery/admin/admin_helper.rb
172
+ - app/helpers/gallery/admin/albums_helper.rb
173
+ - app/helpers/gallery/albums_helper.rb
174
+ - app/helpers/gallery/application_helper.rb
175
+ - app/helpers/gallery/omniauth_callbacks_helper.rb
176
+ - app/helpers/gallery/photos_helper.rb
177
+ - app/models/gallery/album.rb
178
+ - app/models/gallery/identity.rb
179
+ - app/models/gallery/photo.rb
180
+ - app/views/gallery/admin/admin/index.html.erb
181
+ - app/views/gallery/admin/albums/show.html.erb
182
+ - app/views/gallery/albums/_admin_album_element.html.erb
183
+ - app/views/gallery/albums/_album_element.html.erb
184
+ - app/views/gallery/albums/index.html.erb
185
+ - config/initializers/omniauth.rb
186
+ - config/routes.rb
187
+ - db/migrate/20130806170912_create_gallery_identities.rb
188
+ - db/migrate/20130806212451_add_token_to_identity.rb
189
+ - db/migrate/20130806213308_create_gallery_albums.rb
190
+ - db/migrate/20130806214102_create_gallery_photos.rb
191
+ - db/migrate/20130806221405_add_public_to_album.rb
192
+ - db/migrate/20130806221438_add_public_to_photo.rb
193
+ - db/migrate/20130807113616_add_thumbnail_to_photo.rb
194
+ - lib/gallery/engine.rb
195
+ - lib/gallery/version.rb
196
+ - lib/gallery.rb
197
+ - lib/tasks/gallery_tasks.rake
198
+ - MIT-LICENSE
199
+ - Rakefile
200
+ - test/controllers/gallery/admin/admin_controller_test.rb
201
+ - test/controllers/gallery/admin/albums_controller_test.rb
202
+ - test/controllers/gallery/albums_controller_test.rb
203
+ - test/controllers/gallery/omniauth_callbacks_controller_test.rb
204
+ - test/controllers/gallery/photos_controller_test.rb
205
+ - test/dummy/app/assets/javascripts/application.js
206
+ - test/dummy/app/assets/stylesheets/application.css
207
+ - test/dummy/app/controllers/application_controller.rb
208
+ - test/dummy/app/helpers/application_helper.rb
209
+ - test/dummy/app/views/layouts/application.html.erb
210
+ - test/dummy/bin/bundle
211
+ - test/dummy/bin/rails
212
+ - test/dummy/bin/rake
213
+ - test/dummy/config/application.rb
214
+ - test/dummy/config/boot.rb
215
+ - test/dummy/config/database.yml
216
+ - test/dummy/config/environment.rb
217
+ - test/dummy/config/environments/development.rb
218
+ - test/dummy/config/environments/production.rb
219
+ - test/dummy/config/environments/test.rb
220
+ - test/dummy/config/initializers/backtrace_silencers.rb
221
+ - test/dummy/config/initializers/filter_parameter_logging.rb
222
+ - test/dummy/config/initializers/inflections.rb
223
+ - test/dummy/config/initializers/mime_types.rb
224
+ - test/dummy/config/initializers/secret_token.rb
225
+ - test/dummy/config/initializers/session_store.rb
226
+ - test/dummy/config/initializers/wrap_parameters.rb
227
+ - test/dummy/config/locales/en.yml
228
+ - test/dummy/config/routes.rb
229
+ - test/dummy/config.ru
230
+ - test/dummy/public/404.html
231
+ - test/dummy/public/422.html
232
+ - test/dummy/public/500.html
233
+ - test/dummy/public/favicon.ico
234
+ - test/dummy/Rakefile
235
+ - test/dummy/README.rdoc
236
+ - test/fixtures/gallery/albums.yml
237
+ - test/fixtures/gallery/identities.yml
238
+ - test/fixtures/gallery/photos.yml
239
+ - test/gallery_test.rb
240
+ - test/helpers/gallery/admin/admin_helper_test.rb
241
+ - test/helpers/gallery/admin/albums_helper_test.rb
242
+ - test/helpers/gallery/albums_helper_test.rb
243
+ - test/helpers/gallery/omniauth_callbacks_helper_test.rb
244
+ - test/helpers/gallery/photos_helper_test.rb
245
+ - test/integration/navigation_test.rb
246
+ - test/models/gallery/album_test.rb
247
+ - test/models/gallery/identity_test.rb
248
+ - test/models/gallery/photo_test.rb
249
+ - test/test_helper.rb
250
+ homepage: https://www.github.com/nambrot/gallery
251
+ licenses: []
252
+ post_install_message:
253
+ rdoc_options: []
254
+ require_paths:
255
+ - lib
256
+ required_ruby_version: !ruby/object:Gem::Requirement
257
+ none: false
258
+ requirements:
259
+ - - ! '>='
260
+ - !ruby/object:Gem::Version
261
+ version: '0'
262
+ required_rubygems_version: !ruby/object:Gem::Requirement
263
+ none: false
264
+ requirements:
265
+ - - ! '>='
266
+ - !ruby/object:Gem::Version
267
+ version: '0'
268
+ requirements: []
269
+ rubyforge_project:
270
+ rubygems_version: 1.8.25
271
+ signing_key:
272
+ specification_version: 3
273
+ summary: An easy gem to include a gallery to your site
274
+ test_files:
275
+ - test/controllers/gallery/admin/admin_controller_test.rb
276
+ - test/controllers/gallery/admin/albums_controller_test.rb
277
+ - test/controllers/gallery/albums_controller_test.rb
278
+ - test/controllers/gallery/omniauth_callbacks_controller_test.rb
279
+ - test/controllers/gallery/photos_controller_test.rb
280
+ - test/dummy/app/assets/javascripts/application.js
281
+ - test/dummy/app/assets/stylesheets/application.css
282
+ - test/dummy/app/controllers/application_controller.rb
283
+ - test/dummy/app/helpers/application_helper.rb
284
+ - test/dummy/app/views/layouts/application.html.erb
285
+ - test/dummy/bin/bundle
286
+ - test/dummy/bin/rails
287
+ - test/dummy/bin/rake
288
+ - test/dummy/config/application.rb
289
+ - test/dummy/config/boot.rb
290
+ - test/dummy/config/database.yml
291
+ - test/dummy/config/environment.rb
292
+ - test/dummy/config/environments/development.rb
293
+ - test/dummy/config/environments/production.rb
294
+ - test/dummy/config/environments/test.rb
295
+ - test/dummy/config/initializers/backtrace_silencers.rb
296
+ - test/dummy/config/initializers/filter_parameter_logging.rb
297
+ - test/dummy/config/initializers/inflections.rb
298
+ - test/dummy/config/initializers/mime_types.rb
299
+ - test/dummy/config/initializers/secret_token.rb
300
+ - test/dummy/config/initializers/session_store.rb
301
+ - test/dummy/config/initializers/wrap_parameters.rb
302
+ - test/dummy/config/locales/en.yml
303
+ - test/dummy/config/routes.rb
304
+ - test/dummy/config.ru
305
+ - test/dummy/public/404.html
306
+ - test/dummy/public/422.html
307
+ - test/dummy/public/500.html
308
+ - test/dummy/public/favicon.ico
309
+ - test/dummy/Rakefile
310
+ - test/dummy/README.rdoc
311
+ - test/fixtures/gallery/albums.yml
312
+ - test/fixtures/gallery/identities.yml
313
+ - test/fixtures/gallery/photos.yml
314
+ - test/gallery_test.rb
315
+ - test/helpers/gallery/admin/admin_helper_test.rb
316
+ - test/helpers/gallery/admin/albums_helper_test.rb
317
+ - test/helpers/gallery/albums_helper_test.rb
318
+ - test/helpers/gallery/omniauth_callbacks_helper_test.rb
319
+ - test/helpers/gallery/photos_helper_test.rb
320
+ - test/integration/navigation_test.rb
321
+ - test/models/gallery/album_test.rb
322
+ - test/models/gallery/identity_test.rb
323
+ - test/models/gallery/photo_test.rb
324
+ - test/test_helper.rb