install_theme 0.4.1 → 0.5.0
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +4 -0
- data/Manifest.txt +145 -0
- data/lib/install_theme.rb +43 -13
- data/spec/expected/rails/bloganje/app/views/layouts/application.html.haml +90 -0
- data/spec/expected/rails/bloganje/public/stylesheets/ie-sucks.css +140 -21
- data/spec/expected/rails/bloganje/public/stylesheets/sass/style.sass +479 -0
- data/spec/expected/rails/djclub/README +243 -0
- data/spec/expected/rails/djclub/Rakefile +10 -0
- data/spec/expected/rails/djclub/app/controllers/application_controller.rb +10 -0
- data/spec/expected/rails/djclub/app/helpers/application_helper.rb +3 -0
- data/spec/expected/rails/djclub/app/views/layouts/application.html.erb +19 -0
- data/spec/expected/rails/djclub/config/boot.rb +110 -0
- data/spec/expected/rails/djclub/config/database.yml +22 -0
- data/spec/expected/rails/djclub/config/environment.rb +41 -0
- data/spec/expected/rails/djclub/config/environments/development.rb +17 -0
- data/spec/expected/rails/djclub/config/environments/production.rb +28 -0
- data/spec/expected/rails/djclub/config/environments/test.rb +28 -0
- data/spec/expected/rails/djclub/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/expected/rails/djclub/config/initializers/inflections.rb +10 -0
- data/spec/expected/rails/djclub/config/initializers/mime_types.rb +5 -0
- data/spec/expected/rails/djclub/config/initializers/new_rails_defaults.rb +21 -0
- data/spec/expected/rails/djclub/config/initializers/session_store.rb +15 -0
- data/spec/expected/rails/djclub/config/locales/en.yml +5 -0
- data/spec/expected/rails/djclub/config/routes.rb +43 -0
- data/spec/expected/rails/djclub/db/seeds.rb +7 -0
- data/spec/expected/rails/djclub/doc/README_FOR_APP +2 -0
- data/spec/expected/rails/djclub/public/404.html +30 -0
- data/spec/expected/rails/djclub/public/422.html +30 -0
- data/spec/expected/rails/djclub/public/500.html +30 -0
- data/spec/expected/rails/djclub/public/favicon.ico +0 -0
- data/spec/expected/rails/djclub/public/images/bodybg.gif +0 -0
- data/spec/expected/rails/djclub/public/images/contentbg.gif +0 -0
- data/spec/expected/rails/djclub/public/images/djset.gif +0 -0
- data/spec/expected/rails/djclub/public/images/footerbg.gif +0 -0
- data/spec/expected/rails/djclub/public/images/header.jpg +0 -0
- data/spec/expected/rails/djclub/public/images/leftbg.gif +0 -0
- data/spec/expected/rails/djclub/public/images/middlebg.gif +0 -0
- data/spec/expected/rails/djclub/public/images/navbottom.gif +0 -0
- data/spec/expected/rails/djclub/public/images/navtop.gif +0 -0
- data/spec/expected/rails/djclub/public/images/photos.jpg +0 -0
- data/spec/expected/rails/djclub/public/images/rails.png +0 -0
- data/spec/expected/rails/djclub/public/images/rightbg.gif +0 -0
- data/spec/expected/rails/djclub/public/images/timetoparty.jpg +0 -0
- data/spec/expected/rails/djclub/public/index.html +275 -0
- data/spec/expected/rails/djclub/public/javascripts/application.js +2 -0
- data/spec/expected/rails/djclub/public/javascripts/controls.js +963 -0
- data/spec/expected/rails/djclub/public/javascripts/dragdrop.js +973 -0
- data/spec/expected/rails/djclub/public/javascripts/effects.js +1128 -0
- data/spec/expected/rails/djclub/public/javascripts/prototype.js +4320 -0
- data/spec/expected/rails/djclub/public/robots.txt +5 -0
- data/spec/expected/rails/djclub/public/stylesheets/style.css +191 -0
- data/spec/expected/rails/djclub/script/about +4 -0
- data/spec/expected/rails/djclub/script/console +3 -0
- data/spec/expected/rails/djclub/script/dbconsole +3 -0
- data/spec/expected/rails/djclub/script/destroy +3 -0
- data/spec/expected/rails/djclub/script/generate +3 -0
- data/spec/expected/rails/djclub/script/performance/benchmarker +3 -0
- data/spec/expected/rails/djclub/script/performance/profiler +3 -0
- data/spec/expected/rails/djclub/script/plugin +3 -0
- data/spec/expected/rails/djclub/script/runner +3 -0
- data/spec/expected/rails/djclub/script/server +3 -0
- data/spec/expected/rails/djclub/test/performance/browsing_test.rb +9 -0
- data/spec/expected/rails/djclub/test/test_helper.rb +38 -0
- data/spec/expected/rails/the-hobbit-website-template/README +243 -0
- data/spec/expected/rails/the-hobbit-website-template/Rakefile +10 -0
- data/spec/expected/rails/the-hobbit-website-template/app/controllers/application_controller.rb +10 -0
- data/spec/expected/rails/the-hobbit-website-template/app/helpers/application_helper.rb +3 -0
- data/spec/expected/rails/the-hobbit-website-template/app/views/layouts/application.html.erb +53 -0
- data/spec/expected/rails/the-hobbit-website-template/config/boot.rb +110 -0
- data/spec/expected/rails/the-hobbit-website-template/config/database.yml +22 -0
- data/spec/expected/rails/the-hobbit-website-template/config/environment.rb +41 -0
- data/spec/expected/rails/the-hobbit-website-template/config/environments/development.rb +17 -0
- data/spec/expected/rails/the-hobbit-website-template/config/environments/production.rb +28 -0
- data/spec/expected/rails/the-hobbit-website-template/config/environments/test.rb +28 -0
- data/spec/expected/rails/the-hobbit-website-template/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/expected/rails/the-hobbit-website-template/config/initializers/inflections.rb +10 -0
- data/spec/expected/rails/the-hobbit-website-template/config/initializers/mime_types.rb +5 -0
- data/spec/expected/rails/the-hobbit-website-template/config/initializers/new_rails_defaults.rb +21 -0
- data/spec/expected/rails/the-hobbit-website-template/config/initializers/session_store.rb +15 -0
- data/spec/expected/rails/the-hobbit-website-template/config/locales/en.yml +5 -0
- data/spec/expected/rails/the-hobbit-website-template/config/routes.rb +43 -0
- data/spec/expected/rails/the-hobbit-website-template/db/seeds.rb +7 -0
- data/spec/expected/rails/the-hobbit-website-template/doc/README_FOR_APP +2 -0
- data/spec/expected/rails/the-hobbit-website-template/public/404.html +30 -0
- data/spec/expected/rails/the-hobbit-website-template/public/422.html +30 -0
- data/spec/expected/rails/the-hobbit-website-template/public/500.html +30 -0
- data/spec/expected/rails/the-hobbit-website-template/public/favicon.ico +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/bg.jpg +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/bgcontainer.jpg +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/bgcontent.gif +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/bgfooter.gif +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/divider.gif +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/gfx.jpg +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/header.jpg +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/map.jpg +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/pattern.gif +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/quote.gif +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/rails.png +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/images/stripes.gif +0 -0
- data/spec/expected/rails/the-hobbit-website-template/public/index.html +275 -0
- data/spec/expected/rails/the-hobbit-website-template/public/javascripts/application.js +2 -0
- data/spec/expected/rails/the-hobbit-website-template/public/javascripts/controls.js +963 -0
- data/spec/expected/rails/the-hobbit-website-template/public/javascripts/dragdrop.js +973 -0
- data/spec/expected/rails/the-hobbit-website-template/public/javascripts/effects.js +1128 -0
- data/spec/expected/rails/the-hobbit-website-template/public/javascripts/prototype.js +4320 -0
- data/spec/expected/rails/the-hobbit-website-template/public/robots.txt +5 -0
- data/spec/expected/rails/the-hobbit-website-template/public/stylesheets/default.css +185 -0
- data/spec/expected/rails/the-hobbit-website-template/script/about +4 -0
- data/spec/expected/rails/the-hobbit-website-template/script/console +3 -0
- data/spec/expected/rails/the-hobbit-website-template/script/dbconsole +3 -0
- data/spec/expected/rails/the-hobbit-website-template/script/destroy +3 -0
- data/spec/expected/rails/the-hobbit-website-template/script/generate +3 -0
- data/spec/expected/rails/the-hobbit-website-template/script/performance/benchmarker +3 -0
- data/spec/expected/rails/the-hobbit-website-template/script/performance/profiler +3 -0
- data/spec/expected/rails/the-hobbit-website-template/script/plugin +3 -0
- data/spec/expected/rails/the-hobbit-website-template/script/runner +3 -0
- data/spec/expected/rails/the-hobbit-website-template/script/server +3 -0
- data/spec/expected/rails/the-hobbit-website-template/test/performance/browsing_test.rb +9 -0
- data/spec/expected/rails/the-hobbit-website-template/test/test_helper.rb +38 -0
- data/spec/fixtures/djclub/djclub.psd +0 -0
- data/spec/fixtures/djclub/images/bodybg.gif +0 -0
- data/spec/fixtures/djclub/images/contentbg.gif +0 -0
- data/spec/fixtures/djclub/images/djset.gif +0 -0
- data/spec/fixtures/djclub/images/footerbg.gif +0 -0
- data/spec/fixtures/djclub/images/header.jpg +0 -0
- data/spec/fixtures/djclub/images/leftbg.gif +0 -0
- data/spec/fixtures/djclub/images/middlebg.gif +0 -0
- data/spec/fixtures/djclub/images/navbottom.gif +0 -0
- data/spec/fixtures/djclub/images/navtop.gif +0 -0
- data/spec/fixtures/djclub/images/photos.jpg +0 -0
- data/spec/fixtures/djclub/images/rightbg.gif +0 -0
- data/spec/fixtures/djclub/images/timetoparty.jpg +0 -0
- data/spec/fixtures/djclub/index.html +54 -0
- data/spec/fixtures/djclub/style.css +191 -0
- data/spec/fixtures/the-hobbit-website-template/default.css +185 -0
- data/spec/fixtures/the-hobbit-website-template/img/bg.jpg +0 -0
- data/spec/fixtures/the-hobbit-website-template/img/bgcontainer.jpg +0 -0
- data/spec/fixtures/the-hobbit-website-template/img/bgcontent.gif +0 -0
- data/spec/fixtures/the-hobbit-website-template/img/bgfooter.gif +0 -0
- data/spec/fixtures/the-hobbit-website-template/img/divider.gif +0 -0
- data/spec/fixtures/the-hobbit-website-template/img/gfx.jpg +0 -0
- data/spec/fixtures/the-hobbit-website-template/img/header.jpg +0 -0
- data/spec/fixtures/the-hobbit-website-template/img/map.jpg +0 -0
- data/spec/fixtures/the-hobbit-website-template/img/pattern.gif +0 -0
- data/spec/fixtures/the-hobbit-website-template/img/quote.gif +0 -0
- data/spec/fixtures/the-hobbit-website-template/img/stripes.gif +0 -0
- data/spec/fixtures/the-hobbit-website-template/index.html +158 -0
- data/spec/fixtures/the-hobbit-website-template/license-readme.txt +53 -0
- data/spec/install_theme_haml_spec.rb +43 -0
- data/spec/install_theme_spec.rb +1 -1
- metadata +146 -1
data/History.txt
CHANGED
data/Manifest.txt
CHANGED
@@ -58,6 +58,7 @@ spec/expected/rails/bloganje/Rakefile
|
|
58
58
|
spec/expected/rails/bloganje/app/controllers/application_controller.rb
|
59
59
|
spec/expected/rails/bloganje/app/helpers/application_helper.rb
|
60
60
|
spec/expected/rails/bloganje/app/views/layouts/application.html.erb
|
61
|
+
spec/expected/rails/bloganje/app/views/layouts/application.html.haml
|
61
62
|
spec/expected/rails/bloganje/config/boot.rb
|
62
63
|
spec/expected/rails/bloganje/config/database.yml
|
63
64
|
spec/expected/rails/bloganje/config/environment.rb
|
@@ -145,6 +146,7 @@ spec/expected/rails/bloganje/public/robots.txt
|
|
145
146
|
spec/expected/rails/bloganje/public/stylesheets/Copy of theme.css
|
146
147
|
spec/expected/rails/bloganje/public/stylesheets/ie-sucks.css
|
147
148
|
spec/expected/rails/bloganje/public/stylesheets/iepngfix.htc
|
149
|
+
spec/expected/rails/bloganje/public/stylesheets/sass/style.sass
|
148
150
|
spec/expected/rails/bloganje/public/stylesheets/style.css
|
149
151
|
spec/expected/rails/bloganje/public/stylesheets/switch.css
|
150
152
|
spec/expected/rails/bloganje/public/stylesheets/theme.css
|
@@ -154,6 +156,119 @@ spec/expected/rails/bloganje/public/stylesheets/theme3.css
|
|
154
156
|
spec/expected/rails/bloganje/public/stylesheets/theme4.css
|
155
157
|
spec/expected/rails/bloganje/test/performance/browsing_test.rb
|
156
158
|
spec/expected/rails/bloganje/test/test_helper.rb
|
159
|
+
spec/expected/rails/djclub/README
|
160
|
+
spec/expected/rails/djclub/Rakefile
|
161
|
+
spec/expected/rails/djclub/app/controllers/application_controller.rb
|
162
|
+
spec/expected/rails/djclub/app/helpers/application_helper.rb
|
163
|
+
spec/expected/rails/djclub/app/views/layouts/application.html.erb
|
164
|
+
spec/expected/rails/djclub/config/boot.rb
|
165
|
+
spec/expected/rails/djclub/config/database.yml
|
166
|
+
spec/expected/rails/djclub/config/environment.rb
|
167
|
+
spec/expected/rails/djclub/config/environments/development.rb
|
168
|
+
spec/expected/rails/djclub/config/environments/production.rb
|
169
|
+
spec/expected/rails/djclub/config/environments/test.rb
|
170
|
+
spec/expected/rails/djclub/config/initializers/backtrace_silencers.rb
|
171
|
+
spec/expected/rails/djclub/config/initializers/inflections.rb
|
172
|
+
spec/expected/rails/djclub/config/initializers/mime_types.rb
|
173
|
+
spec/expected/rails/djclub/config/initializers/new_rails_defaults.rb
|
174
|
+
spec/expected/rails/djclub/config/initializers/session_store.rb
|
175
|
+
spec/expected/rails/djclub/config/locales/en.yml
|
176
|
+
spec/expected/rails/djclub/config/routes.rb
|
177
|
+
spec/expected/rails/djclub/db/seeds.rb
|
178
|
+
spec/expected/rails/djclub/doc/README_FOR_APP
|
179
|
+
spec/expected/rails/djclub/public/404.html
|
180
|
+
spec/expected/rails/djclub/public/422.html
|
181
|
+
spec/expected/rails/djclub/public/500.html
|
182
|
+
spec/expected/rails/djclub/public/favicon.ico
|
183
|
+
spec/expected/rails/djclub/public/images/bodybg.gif
|
184
|
+
spec/expected/rails/djclub/public/images/contentbg.gif
|
185
|
+
spec/expected/rails/djclub/public/images/djset.gif
|
186
|
+
spec/expected/rails/djclub/public/images/footerbg.gif
|
187
|
+
spec/expected/rails/djclub/public/images/header.jpg
|
188
|
+
spec/expected/rails/djclub/public/images/leftbg.gif
|
189
|
+
spec/expected/rails/djclub/public/images/middlebg.gif
|
190
|
+
spec/expected/rails/djclub/public/images/navbottom.gif
|
191
|
+
spec/expected/rails/djclub/public/images/navtop.gif
|
192
|
+
spec/expected/rails/djclub/public/images/photos.jpg
|
193
|
+
spec/expected/rails/djclub/public/images/rails.png
|
194
|
+
spec/expected/rails/djclub/public/images/rightbg.gif
|
195
|
+
spec/expected/rails/djclub/public/images/timetoparty.jpg
|
196
|
+
spec/expected/rails/djclub/public/index.html
|
197
|
+
spec/expected/rails/djclub/public/javascripts/application.js
|
198
|
+
spec/expected/rails/djclub/public/javascripts/controls.js
|
199
|
+
spec/expected/rails/djclub/public/javascripts/dragdrop.js
|
200
|
+
spec/expected/rails/djclub/public/javascripts/effects.js
|
201
|
+
spec/expected/rails/djclub/public/javascripts/prototype.js
|
202
|
+
spec/expected/rails/djclub/public/robots.txt
|
203
|
+
spec/expected/rails/djclub/public/stylesheets/style.css
|
204
|
+
spec/expected/rails/djclub/script/about
|
205
|
+
spec/expected/rails/djclub/script/console
|
206
|
+
spec/expected/rails/djclub/script/dbconsole
|
207
|
+
spec/expected/rails/djclub/script/destroy
|
208
|
+
spec/expected/rails/djclub/script/generate
|
209
|
+
spec/expected/rails/djclub/script/performance/benchmarker
|
210
|
+
spec/expected/rails/djclub/script/performance/profiler
|
211
|
+
spec/expected/rails/djclub/script/plugin
|
212
|
+
spec/expected/rails/djclub/script/runner
|
213
|
+
spec/expected/rails/djclub/script/server
|
214
|
+
spec/expected/rails/djclub/test/performance/browsing_test.rb
|
215
|
+
spec/expected/rails/djclub/test/test_helper.rb
|
216
|
+
spec/expected/rails/the-hobbit-website-template/README
|
217
|
+
spec/expected/rails/the-hobbit-website-template/Rakefile
|
218
|
+
spec/expected/rails/the-hobbit-website-template/app/controllers/application_controller.rb
|
219
|
+
spec/expected/rails/the-hobbit-website-template/app/helpers/application_helper.rb
|
220
|
+
spec/expected/rails/the-hobbit-website-template/app/views/layouts/application.html.erb
|
221
|
+
spec/expected/rails/the-hobbit-website-template/config/boot.rb
|
222
|
+
spec/expected/rails/the-hobbit-website-template/config/database.yml
|
223
|
+
spec/expected/rails/the-hobbit-website-template/config/environment.rb
|
224
|
+
spec/expected/rails/the-hobbit-website-template/config/environments/development.rb
|
225
|
+
spec/expected/rails/the-hobbit-website-template/config/environments/production.rb
|
226
|
+
spec/expected/rails/the-hobbit-website-template/config/environments/test.rb
|
227
|
+
spec/expected/rails/the-hobbit-website-template/config/initializers/backtrace_silencers.rb
|
228
|
+
spec/expected/rails/the-hobbit-website-template/config/initializers/inflections.rb
|
229
|
+
spec/expected/rails/the-hobbit-website-template/config/initializers/mime_types.rb
|
230
|
+
spec/expected/rails/the-hobbit-website-template/config/initializers/new_rails_defaults.rb
|
231
|
+
spec/expected/rails/the-hobbit-website-template/config/initializers/session_store.rb
|
232
|
+
spec/expected/rails/the-hobbit-website-template/config/locales/en.yml
|
233
|
+
spec/expected/rails/the-hobbit-website-template/config/routes.rb
|
234
|
+
spec/expected/rails/the-hobbit-website-template/db/seeds.rb
|
235
|
+
spec/expected/rails/the-hobbit-website-template/doc/README_FOR_APP
|
236
|
+
spec/expected/rails/the-hobbit-website-template/public/404.html
|
237
|
+
spec/expected/rails/the-hobbit-website-template/public/422.html
|
238
|
+
spec/expected/rails/the-hobbit-website-template/public/500.html
|
239
|
+
spec/expected/rails/the-hobbit-website-template/public/favicon.ico
|
240
|
+
spec/expected/rails/the-hobbit-website-template/public/images/bg.jpg
|
241
|
+
spec/expected/rails/the-hobbit-website-template/public/images/bgcontainer.jpg
|
242
|
+
spec/expected/rails/the-hobbit-website-template/public/images/bgcontent.gif
|
243
|
+
spec/expected/rails/the-hobbit-website-template/public/images/bgfooter.gif
|
244
|
+
spec/expected/rails/the-hobbit-website-template/public/images/divider.gif
|
245
|
+
spec/expected/rails/the-hobbit-website-template/public/images/gfx.jpg
|
246
|
+
spec/expected/rails/the-hobbit-website-template/public/images/header.jpg
|
247
|
+
spec/expected/rails/the-hobbit-website-template/public/images/map.jpg
|
248
|
+
spec/expected/rails/the-hobbit-website-template/public/images/pattern.gif
|
249
|
+
spec/expected/rails/the-hobbit-website-template/public/images/quote.gif
|
250
|
+
spec/expected/rails/the-hobbit-website-template/public/images/rails.png
|
251
|
+
spec/expected/rails/the-hobbit-website-template/public/images/stripes.gif
|
252
|
+
spec/expected/rails/the-hobbit-website-template/public/index.html
|
253
|
+
spec/expected/rails/the-hobbit-website-template/public/javascripts/application.js
|
254
|
+
spec/expected/rails/the-hobbit-website-template/public/javascripts/controls.js
|
255
|
+
spec/expected/rails/the-hobbit-website-template/public/javascripts/dragdrop.js
|
256
|
+
spec/expected/rails/the-hobbit-website-template/public/javascripts/effects.js
|
257
|
+
spec/expected/rails/the-hobbit-website-template/public/javascripts/prototype.js
|
258
|
+
spec/expected/rails/the-hobbit-website-template/public/robots.txt
|
259
|
+
spec/expected/rails/the-hobbit-website-template/public/stylesheets/default.css
|
260
|
+
spec/expected/rails/the-hobbit-website-template/script/about
|
261
|
+
spec/expected/rails/the-hobbit-website-template/script/console
|
262
|
+
spec/expected/rails/the-hobbit-website-template/script/dbconsole
|
263
|
+
spec/expected/rails/the-hobbit-website-template/script/destroy
|
264
|
+
spec/expected/rails/the-hobbit-website-template/script/generate
|
265
|
+
spec/expected/rails/the-hobbit-website-template/script/performance/benchmarker
|
266
|
+
spec/expected/rails/the-hobbit-website-template/script/performance/profiler
|
267
|
+
spec/expected/rails/the-hobbit-website-template/script/plugin
|
268
|
+
spec/expected/rails/the-hobbit-website-template/script/runner
|
269
|
+
spec/expected/rails/the-hobbit-website-template/script/server
|
270
|
+
spec/expected/rails/the-hobbit-website-template/test/performance/browsing_test.rb
|
271
|
+
spec/expected/rails/the-hobbit-website-template/test/test_helper.rb
|
157
272
|
spec/expected/rails/webresourcedepot/README
|
158
273
|
spec/expected/rails/webresourcedepot/Rakefile
|
159
274
|
spec/expected/rails/webresourcedepot/app/controllers/application_controller.rb
|
@@ -286,6 +401,35 @@ spec/fixtures/bloganje/img/icons/world.png
|
|
286
401
|
spec/fixtures/bloganje/index.html
|
287
402
|
spec/fixtures/bloganje/psd/template.psd
|
288
403
|
spec/fixtures/bloganje/users.html
|
404
|
+
spec/fixtures/djclub/djclub.psd
|
405
|
+
spec/fixtures/djclub/images/bodybg.gif
|
406
|
+
spec/fixtures/djclub/images/contentbg.gif
|
407
|
+
spec/fixtures/djclub/images/djset.gif
|
408
|
+
spec/fixtures/djclub/images/footerbg.gif
|
409
|
+
spec/fixtures/djclub/images/header.jpg
|
410
|
+
spec/fixtures/djclub/images/leftbg.gif
|
411
|
+
spec/fixtures/djclub/images/middlebg.gif
|
412
|
+
spec/fixtures/djclub/images/navbottom.gif
|
413
|
+
spec/fixtures/djclub/images/navtop.gif
|
414
|
+
spec/fixtures/djclub/images/photos.jpg
|
415
|
+
spec/fixtures/djclub/images/rightbg.gif
|
416
|
+
spec/fixtures/djclub/images/timetoparty.jpg
|
417
|
+
spec/fixtures/djclub/index.html
|
418
|
+
spec/fixtures/djclub/style.css
|
419
|
+
spec/fixtures/the-hobbit-website-template/default.css
|
420
|
+
spec/fixtures/the-hobbit-website-template/img/bg.jpg
|
421
|
+
spec/fixtures/the-hobbit-website-template/img/bgcontainer.jpg
|
422
|
+
spec/fixtures/the-hobbit-website-template/img/bgcontent.gif
|
423
|
+
spec/fixtures/the-hobbit-website-template/img/bgfooter.gif
|
424
|
+
spec/fixtures/the-hobbit-website-template/img/divider.gif
|
425
|
+
spec/fixtures/the-hobbit-website-template/img/gfx.jpg
|
426
|
+
spec/fixtures/the-hobbit-website-template/img/header.jpg
|
427
|
+
spec/fixtures/the-hobbit-website-template/img/map.jpg
|
428
|
+
spec/fixtures/the-hobbit-website-template/img/pattern.gif
|
429
|
+
spec/fixtures/the-hobbit-website-template/img/quote.gif
|
430
|
+
spec/fixtures/the-hobbit-website-template/img/stripes.gif
|
431
|
+
spec/fixtures/the-hobbit-website-template/index.html
|
432
|
+
spec/fixtures/the-hobbit-website-template/license-readme.txt
|
289
433
|
spec/fixtures/webresourcedepot/README.md
|
290
434
|
spec/fixtures/webresourcedepot/css/all.css
|
291
435
|
spec/fixtures/webresourcedepot/img/Thumbs.db
|
@@ -315,6 +459,7 @@ spec/fixtures/webresourcedepot/img/tab-right.gif
|
|
315
459
|
spec/fixtures/webresourcedepot/img/tab.gif
|
316
460
|
spec/fixtures/webresourcedepot/index.html
|
317
461
|
spec/install_theme_cli_spec.rb
|
462
|
+
spec/install_theme_haml_spec.rb
|
318
463
|
spec/install_theme_spec.rb
|
319
464
|
spec/matchers/have_same_contents_as.rb
|
320
465
|
spec/spec.opts
|
data/lib/install_theme.rb
CHANGED
@@ -6,7 +6,7 @@ require 'rubigen'
|
|
6
6
|
require 'rubigen/scripts/generate'
|
7
7
|
|
8
8
|
class InstallTheme
|
9
|
-
VERSION = "0.
|
9
|
+
VERSION = "0.5.0"
|
10
10
|
|
11
11
|
attr_reader :template_root, :rails_root, :index_path, :template_type
|
12
12
|
attr_reader :stylesheet_dir, :javascript_dir, :image_dir
|
@@ -33,6 +33,7 @@ class InstallTheme
|
|
33
33
|
@stdout = options[:stdout] || @stdout || $stdout
|
34
34
|
@inside_yields_originals = {}
|
35
35
|
convert_file_to_layout(index_path, 'app/views/layouts/application.html.erb')
|
36
|
+
convert_to_haml('app/views/layouts/application.html.erb') if haml?
|
36
37
|
prepare_assets
|
37
38
|
run_generator(options)
|
38
39
|
show_readme
|
@@ -42,7 +43,6 @@ class InstallTheme
|
|
42
43
|
# and is accessed via source_root within the generator.
|
43
44
|
def template_temp_path
|
44
45
|
@template_temp_path ||= begin
|
45
|
-
tmp_dir = ENV['TMPDIR'] || '/tmp'
|
46
46
|
template_path = File.join(tmp_dir, "install_theme", "templates")
|
47
47
|
end
|
48
48
|
end
|
@@ -98,14 +98,30 @@ class InstallTheme
|
|
98
98
|
f << contents
|
99
99
|
end
|
100
100
|
end
|
101
|
+
|
102
|
+
def convert_to_haml(path)
|
103
|
+
from_path = File.join(template_temp_path, path)
|
104
|
+
haml_path = from_path.gsub(/erb$/, "haml")
|
105
|
+
`html2haml "#{from_path}" "#{haml_path}"`
|
106
|
+
FileUtils.rm_rf(from_path)
|
107
|
+
end
|
108
|
+
|
109
|
+
def convert_to_sass(from_path)
|
110
|
+
sass_path = from_path.gsub(/css$/, "sass").gsub(%r{public/stylesheets/}, 'public/stylesheets/sass/')
|
111
|
+
FileUtils.mkdir_p(File.dirname(sass_path))
|
112
|
+
`css2sass "#{from_path}" "#{sass_path}"`
|
113
|
+
FileUtils.rm_rf(from_path)
|
114
|
+
end
|
101
115
|
|
102
116
|
def prepare_assets
|
103
117
|
template_stylesheets.each do |file|
|
104
|
-
File.
|
118
|
+
target_path = File.join(template_temp_path, 'public/stylesheets', File.basename(file))
|
119
|
+
File.open(target_path, "w") do |f|
|
105
120
|
contents = File.read(file)
|
106
121
|
contents.gsub!(%r{url\((["']?)[./]*#{image_dir}}, 'url(\1/images')
|
107
122
|
f << contents
|
108
123
|
end
|
124
|
+
convert_to_sass(target_path) if haml?
|
109
125
|
end
|
110
126
|
template_javascripts.each do |file|
|
111
127
|
FileUtils.cp_r(file, File.join(template_temp_path, 'public/javascripts'))
|
@@ -174,15 +190,15 @@ class InstallTheme
|
|
174
190
|
end
|
175
191
|
|
176
192
|
def template_stylesheets
|
177
|
-
Dir[File.join(template_root, stylesheet_dir, '
|
193
|
+
Dir[File.join(template_root, stylesheet_dir, '**/*.css')]
|
178
194
|
end
|
179
195
|
|
180
196
|
def template_javascripts
|
181
|
-
Dir[File.join(template_root, javascript_dir, '
|
197
|
+
Dir[File.join(template_root, javascript_dir, '**/*.js')]
|
182
198
|
end
|
183
199
|
|
184
200
|
def template_images
|
185
|
-
Dir[File.join(template_root, image_dir, '
|
201
|
+
Dir[File.join(template_root, image_dir, '**/*.{jpg,png,gif}')]
|
186
202
|
end
|
187
203
|
|
188
204
|
def show_readme
|
@@ -192,17 +208,31 @@ class InstallTheme
|
|
192
208
|
|
193
209
|
README
|
194
210
|
stdout.puts "You are using named yields. Here are examples how to use them: "
|
195
|
-
stdout.puts
|
196
|
-
<% content_for :head do -%>
|
197
|
-
<script>...</script>
|
198
|
-
<% end -%>
|
199
|
-
EOS
|
211
|
+
stdout.puts show_content_for(:head, '<script></script>')
|
200
212
|
inside_yields_originals.to_a.each do |key, original_contents|
|
201
|
-
stdout.puts
|
213
|
+
stdout.puts show_content_for(key, original_contents)
|
214
|
+
end
|
215
|
+
end
|
216
|
+
|
217
|
+
def show_content_for(key, contents)
|
218
|
+
if haml?
|
219
|
+
contents_file = File.join(tmp_dir, "partial.html")
|
220
|
+
File.open(contents_file, "w") { |f| f << contents }
|
221
|
+
haml_contents = `html2haml #{contents_file}`
|
222
|
+
<<-EOS.gsub(/^ /, '')
|
223
|
+
- content_for :#{key} do
|
224
|
+
#{haml_contents}
|
225
|
+
EOS
|
226
|
+
else
|
227
|
+
<<-EOS.gsub(/^ /, '')
|
202
228
|
<% content_for :#{key} do -%>
|
203
|
-
#{
|
229
|
+
#{contents}
|
204
230
|
<% end -%>
|
205
231
|
EOS
|
206
232
|
end
|
207
233
|
end
|
234
|
+
|
235
|
+
def tmp_dir
|
236
|
+
ENV['TMPDIR'] || '/tmp'
|
237
|
+
end
|
208
238
|
end
|
@@ -0,0 +1,90 @@
|
|
1
|
+
!!!
|
2
|
+
%html{ :xmlns => "http://www.w3.org/1999/xhtml" }
|
3
|
+
%head
|
4
|
+
%meta{ :content => "text/html; charset=utf-8" }
|
5
|
+
%title
|
6
|
+
Dashboard - Admin Template
|
7
|
+
%link{ :href => "/stylesheets/theme.css", :rel => "stylesheet", :type => "text/css" }
|
8
|
+
%link{ :href => "/stylesheets/style.css", :rel => "stylesheet", :type => "text/css" }
|
9
|
+
%script
|
10
|
+
var StyleFile = "theme" + document.cookie.charAt(6) + ".css";
|
11
|
+
document.writeln('<link rel="stylesheet" type="text/css" href="/stylesheets/' + StyleFile + '">');
|
12
|
+
/
|
13
|
+
[if IE]>
|
14
|
+
<link rel="stylesheet" type="text/css" href="/stylesheets/ie-sucks.css" />
|
15
|
+
<![endif]
|
16
|
+
= yield(:head)
|
17
|
+
%body
|
18
|
+
#container
|
19
|
+
#header
|
20
|
+
%h2
|
21
|
+
= yield(:header)
|
22
|
+
#topmenu
|
23
|
+
%ul
|
24
|
+
%li.current
|
25
|
+
%a{ :href => "index.html" }
|
26
|
+
Dashboard
|
27
|
+
%li
|
28
|
+
%a{ :href => "#" }
|
29
|
+
Orders
|
30
|
+
%li
|
31
|
+
%a{ :href => "users.html" }
|
32
|
+
Users
|
33
|
+
%li
|
34
|
+
%a{ :href => "#" }
|
35
|
+
Manage
|
36
|
+
%li
|
37
|
+
%a{ :href => "#" }
|
38
|
+
CMS
|
39
|
+
%li
|
40
|
+
%a{ :href => "#" }
|
41
|
+
Statistics
|
42
|
+
%li
|
43
|
+
%a{ :href => "#" }
|
44
|
+
Settings
|
45
|
+
#top-panel
|
46
|
+
#panel
|
47
|
+
%ul
|
48
|
+
%li
|
49
|
+
%a.report{ :href => "#" }
|
50
|
+
Sales Report
|
51
|
+
%li
|
52
|
+
%a.report_seo{ :href => "#" }
|
53
|
+
SEO Report
|
54
|
+
%li
|
55
|
+
%a.search{ :href => "#" }
|
56
|
+
Search
|
57
|
+
%li
|
58
|
+
%a.feed{ :href => "#" }
|
59
|
+
RSS Feed
|
60
|
+
#wrapper
|
61
|
+
#content
|
62
|
+
= yield
|
63
|
+
#sidebar
|
64
|
+
= yield(:sidebar)
|
65
|
+
#footer
|
66
|
+
#credits
|
67
|
+
Template by
|
68
|
+
%a{ :href => "http://www.bloganje.com" }
|
69
|
+
Bloganje
|
70
|
+
#styleswitcher
|
71
|
+
%ul
|
72
|
+
%li
|
73
|
+
%a#defswitch{ :href => "javascript: document.cookie='theme='; window.location.reload();", :title => "Default" }
|
74
|
+
d
|
75
|
+
%li
|
76
|
+
%a#blueswitch{ :href => "javascript: document.cookie='theme=1'; window.location.reload();", :title => "Blue" }
|
77
|
+
b
|
78
|
+
%li
|
79
|
+
%a#greenswitch{ :href => "javascript: document.cookie='theme=2'; window.location.reload();", :title => "Green" }
|
80
|
+
g
|
81
|
+
%li
|
82
|
+
%a#brownswitch{ :href => "javascript: document.cookie='theme=3'; window.location.reload();", :title => "Brown" }
|
83
|
+
b
|
84
|
+
%li
|
85
|
+
%a#mixswitch{ :href => "javascript: document.cookie='theme=4'; window.location.reload();", :title => "Mix" }
|
86
|
+
m
|
87
|
+
%li
|
88
|
+
%a#defswitch{ :href => "javascript: document.cookie='theme=5'; window.location.reload();", :title => "Mix" }
|
89
|
+
m
|
90
|
+
%br
|
@@ -1,21 +1,140 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
#
|
8
|
-
|
9
|
-
|
10
|
-
#
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
1
|
+
body
|
2
|
+
background: #f7f6f0 url(/images/bg.jpg) repeat-x top
|
3
|
+
color: #202020
|
4
|
+
|
5
|
+
|
6
|
+
a
|
7
|
+
color: #993300
|
8
|
+
|
9
|
+
&:visited
|
10
|
+
color: #993300
|
11
|
+
|
12
|
+
|
13
|
+
input, select
|
14
|
+
border: 1px solid #e8e7e1
|
15
|
+
|
16
|
+
|
17
|
+
#header h2
|
18
|
+
color: #FFF
|
19
|
+
|
20
|
+
|
21
|
+
#content
|
22
|
+
background: #FFF
|
23
|
+
|
24
|
+
|
25
|
+
#sidebar
|
26
|
+
background: #FFF
|
27
|
+
|
28
|
+
h3
|
29
|
+
background: #f7f6f0
|
30
|
+
border-bottom: 1px solid #e8e7e1
|
31
|
+
|
32
|
+
|
33
|
+
#topmenu
|
34
|
+
a
|
35
|
+
color: #f7f6f0
|
36
|
+
background: #cc3300
|
37
|
+
|
38
|
+
&:visited
|
39
|
+
color: #f7f6f0
|
40
|
+
background: #cc3300
|
41
|
+
|
42
|
+
&:hover
|
43
|
+
color: #FFF
|
44
|
+
|
45
|
+
.current a
|
46
|
+
color: #993400
|
47
|
+
background: #FFF url(/images/bg_menu_red.jpg) repeat-x top
|
48
|
+
border-left: #FFF 1px solid
|
49
|
+
border-right: #FFF 1px solid
|
50
|
+
|
51
|
+
&:hover, &:visited
|
52
|
+
color: #993400
|
53
|
+
background: #FFF url(/images/bg_menu_red.jpg) repeat-x top
|
54
|
+
border-left: #FFF 1px solid
|
55
|
+
border-right: #FFF 1px solid
|
56
|
+
|
57
|
+
|
58
|
+
#top-panel
|
59
|
+
background: #FFF
|
60
|
+
|
61
|
+
|
62
|
+
table
|
63
|
+
background: none
|
64
|
+
|
65
|
+
|
66
|
+
td, th
|
67
|
+
border: 1px solid #e8e7e1
|
68
|
+
|
69
|
+
|
70
|
+
thead
|
71
|
+
background: #f7f6f0
|
72
|
+
|
73
|
+
|
74
|
+
#styleswitcher
|
75
|
+
background: #FFFFFF
|
76
|
+
|
77
|
+
|
78
|
+
#footer
|
79
|
+
background: #FFF
|
80
|
+
|
81
|
+
|
82
|
+
#box
|
83
|
+
border: 1px solid #e8e7e1
|
84
|
+
|
85
|
+
h3
|
86
|
+
background: #f7f6f0
|
87
|
+
border-bottom: 1px solid #e8e7e1
|
88
|
+
color: #993300
|
89
|
+
|
90
|
+
|
91
|
+
form#form
|
92
|
+
fieldset
|
93
|
+
border: 1px solid #e8e7e1
|
94
|
+
|
95
|
+
legend
|
96
|
+
border: 1px solid #e8e7e1
|
97
|
+
background: #fff url(/images/form_red.gif) repeat-x center left
|
98
|
+
color: #993300
|
99
|
+
|
100
|
+
input
|
101
|
+
border: 1px solid #e8e7e1
|
102
|
+
background: #fff url(/images/form_red.gif) repeat-x top left
|
103
|
+
|
104
|
+
textarea
|
105
|
+
border: 1px solid #e8e7e1
|
106
|
+
background: #fff url(/images/form_red.gif) repeat-x bottom left
|
107
|
+
|
108
|
+
option
|
109
|
+
background: #FFF
|
110
|
+
|
111
|
+
optgroup
|
112
|
+
background: #e8e7e1
|
113
|
+
|
114
|
+
option
|
115
|
+
#button1, #button2
|
116
|
+
color: #c00
|
117
|
+
|
118
|
+
#button1:hover, #button2:hover
|
119
|
+
color: #000
|
120
|
+
|
121
|
+
|
122
|
+
#infobox
|
123
|
+
border: 1px solid #e8e7e1
|
124
|
+
|
125
|
+
h3
|
126
|
+
background: #f7f6f0
|
127
|
+
border-bottom: 1px solid #e8e7e1
|
128
|
+
color: #993300
|
129
|
+
|
130
|
+
|
131
|
+
#rightnow
|
132
|
+
border: 1px solid #e8e7e1
|
133
|
+
|
134
|
+
.reallynow
|
135
|
+
background: #f7f6f0
|
136
|
+
color: #993300
|
137
|
+
|
138
|
+
h3
|
139
|
+
background: #f7f6f0
|
140
|
+
border-bottom: 1px solid #e8e7e1
|