rails_apps_composer 2.2.17 → 2.2.18
Sign up to get free protection for your applications and to get access to all the features.
- data/recipes/controllers.rb +2 -1
- data/recipes/gems.rb +13 -14
- data/recipes/init.rb +13 -1
- data/recipes/prelaunch.rb +1 -0
- data/recipes/views.rb +5 -3
- data/version.rb +1 -1
- metadata +4 -4
data/recipes/controllers.rb
CHANGED
@@ -5,7 +5,8 @@ after_bundler do
|
|
5
5
|
say_wizard "recipe running after 'bundle install'"
|
6
6
|
### APPLICATION_CONTROLLER ###
|
7
7
|
if prefer :authentication, 'omniauth'
|
8
|
-
copy_from_repo 'app/controllers/application_controller.rb', :repo => 'https://raw.github.com/RailsApps/rails3-mongoid-omniauth/master/'
|
8
|
+
#copy_from_repo 'app/controllers/application_controller.rb', :repo => 'https://raw.github.com/RailsApps/rails3-mongoid-omniauth/master/'
|
9
|
+
copy_from_repo 'app/controllers/application_controller-omniauth.rb', :prefs => 'omniauth'
|
9
10
|
end
|
10
11
|
if prefer :authorization, 'cancan'
|
11
12
|
inject_into_file 'app/controllers/application_controller.rb', :before => "\nend" do <<-RUBY
|
data/recipes/gems.rb
CHANGED
@@ -22,7 +22,7 @@ end
|
|
22
22
|
|
23
23
|
## Database Adapter
|
24
24
|
gsub_file 'Gemfile', /gem 'sqlite3'\n/, '' unless prefer :database, 'sqlite'
|
25
|
-
gem 'mongoid', '>= 3.0.
|
25
|
+
gem 'mongoid', '>= 3.0.11' if prefer :orm, 'mongoid'
|
26
26
|
gem 'pg', '>= 0.14.1' if prefer :database, 'postgresql'
|
27
27
|
gem 'mysql2', '>= 0.3.11' if prefer :database, 'mysql'
|
28
28
|
|
@@ -32,7 +32,7 @@ if prefer :templates, 'haml'
|
|
32
32
|
gem 'haml-rails', '>= 0.3.5', :group => :development
|
33
33
|
# hpricot and ruby_parser are needed for conversion of HTML to Haml
|
34
34
|
gem 'hpricot', '>= 0.8.6', :group => :development
|
35
|
-
gem 'ruby_parser', '>=
|
35
|
+
gem 'ruby_parser', '>= 3.0.1', :group => :development
|
36
36
|
end
|
37
37
|
if prefer :templates, 'slim'
|
38
38
|
gem 'slim', '>= 1.3.3'
|
@@ -41,31 +41,29 @@ if prefer :templates, 'slim'
|
|
41
41
|
gem 'haml', '>= 3.1.6', :group => :development
|
42
42
|
gem 'haml-rails', '>= 0.3.5', :group => :development
|
43
43
|
gem 'hpricot', '>= 0.8.6', :group => :development
|
44
|
-
gem 'ruby_parser', '>=
|
44
|
+
gem 'ruby_parser', '>= 3.0.1', :group => :development
|
45
45
|
end
|
46
46
|
|
47
47
|
## Testing Framework
|
48
48
|
if prefer :unit_test, 'rspec'
|
49
49
|
gem 'rspec-rails', '>= 2.11.4', :group => [:development, :test]
|
50
|
-
gem 'capybara', '>= 1.1.
|
50
|
+
gem 'capybara', '>= 1.1.3', :group => :test if prefer :integration, 'rspec-capybara'
|
51
|
+
gem 'database_cleaner', '>= 0.9.1', :group => :test
|
51
52
|
if prefer :orm, 'mongoid'
|
52
|
-
# use the database_cleaner gem to reset the test database
|
53
|
-
gem 'database_cleaner', '>= 0.9.1', :group => :test
|
54
|
-
# include RSpec matchers from the mongoid-rspec gem
|
55
53
|
gem 'mongoid-rspec', '>= 1.4.6', :group => :test
|
56
54
|
end
|
57
|
-
gem 'email_spec', '>= 1.
|
55
|
+
gem 'email_spec', '>= 1.4.0', :group => :test
|
58
56
|
end
|
59
57
|
if prefer :unit_test, 'minitest'
|
60
58
|
gem 'minitest-spec-rails', '>= 3.0.7', :group => :test
|
61
59
|
gem 'minitest-wscolor', '>= 0.0.3', :group => :test
|
62
|
-
gem 'capybara', '>= 1.1.
|
60
|
+
gem 'capybara', '>= 1.1.3', :group => :test if prefer :integration, 'minitest-capybara'
|
63
61
|
end
|
64
62
|
if prefer :integration, 'cucumber'
|
65
63
|
gem 'cucumber-rails', '>= 1.3.0', :group => :test, :require => false
|
66
|
-
gem 'database_cleaner', '>= 0.9.1', :group => :test unless prefer :
|
64
|
+
gem 'database_cleaner', '>= 0.9.1', :group => :test unless prefer :unit_test, 'rspec'
|
67
65
|
gem 'launchy', '>= 2.1.2', :group => :test
|
68
|
-
gem 'capybara', '>= 1.1.
|
66
|
+
gem 'capybara', '>= 1.1.3', :group => :test
|
69
67
|
end
|
70
68
|
gem 'turnip', '>= 1.0.0', :group => :test if prefer :integration, 'turnip'
|
71
69
|
gem 'factory_girl_rails', '>= 4.1.0', :group => [:development, :test] if prefer :fixtures, 'factory_girl'
|
@@ -73,11 +71,12 @@ gem 'fabrication', '>= 2.3.0', :group => [:development, :test] if prefer :fixtur
|
|
73
71
|
gem 'machinist', '>= 2.0', :group => :test if prefer :fixtures, 'machinist'
|
74
72
|
|
75
73
|
## Front-end Framework
|
76
|
-
gem 'bootstrap-sass', '>= 2.1.0
|
74
|
+
gem 'bootstrap-sass', '>= 2.1.1.0' if prefer :bootstrap, 'sass'
|
77
75
|
gem 'compass-rails', '>= 1.0.3', :group => :assets if prefer :frontend, 'foundation'
|
78
76
|
gem 'zurb-foundation', '>= 3.2.0', :group => :assets if prefer :frontend, 'foundation'
|
79
77
|
if prefer :bootstrap, 'less'
|
80
|
-
gem '
|
78
|
+
gem 'less-rails', '>= 2.2.6', :group => :assets
|
79
|
+
gem 'twitter-bootstrap-rails', '>= 2.1.6', :group => :assets
|
81
80
|
# install gem 'therubyracer' to use Less
|
82
81
|
gem 'therubyracer', '>= 0.10.2', :group => :assets, :platform => :ruby
|
83
82
|
end
|
@@ -117,7 +116,7 @@ end
|
|
117
116
|
## Signup App
|
118
117
|
if prefer :railsapps, 'rails-prelaunch-signup'
|
119
118
|
gem 'google_visualr', '>= 2.1.2'
|
120
|
-
gem 'jquery-datatables-rails', '>= 1.11.
|
119
|
+
gem 'jquery-datatables-rails', '>= 1.11.2'
|
121
120
|
end
|
122
121
|
|
123
122
|
## Gems from a defaults file or added interactively
|
data/recipes/init.rb
CHANGED
@@ -6,7 +6,8 @@ after_everything do
|
|
6
6
|
### PREPARE SEED ###
|
7
7
|
if prefer :authentication, 'devise'
|
8
8
|
if (prefer :authorization, 'cancan') && !(prefer :railsapps, 'rails-prelaunch-signup')
|
9
|
-
|
9
|
+
unless prefer :orm, 'mongoid'
|
10
|
+
append_file 'db/seeds.rb' do <<-FILE
|
10
11
|
puts 'CREATING ROLES'
|
11
12
|
Role.create([
|
12
13
|
{ :name => 'admin' },
|
@@ -14,6 +15,17 @@ Role.create([
|
|
14
15
|
{ :name => 'VIP' }
|
15
16
|
], :without_protection => true)
|
16
17
|
FILE
|
18
|
+
end
|
19
|
+
else
|
20
|
+
append_file 'db/seeds.rb' do <<-FILE
|
21
|
+
puts 'CREATING ROLES'
|
22
|
+
Role.mongo_session['roles'].insert([
|
23
|
+
{ :name => 'admin' },
|
24
|
+
{ :name => 'user' },
|
25
|
+
{ :name => 'VIP' }
|
26
|
+
])
|
27
|
+
FILE
|
28
|
+
end
|
17
29
|
end
|
18
30
|
end
|
19
31
|
if (prefer :devise_modules, 'confirmable') || (prefer :devise_modules, 'invitable')
|
data/recipes/prelaunch.rb
CHANGED
@@ -89,6 +89,7 @@ if prefer :railsapps, 'rails-prelaunch-signup'
|
|
89
89
|
copy_from_repo 'app/views/user_mailer/welcome_email.html.erb', :repo => repo
|
90
90
|
copy_from_repo 'app/views/user_mailer/welcome_email.text.erb', :repo => repo
|
91
91
|
copy_from_repo 'app/views/users/index.html.erb', :repo => repo
|
92
|
+
remove_file 'app/views/users/_user.html.erb'
|
92
93
|
copy_from_repo 'public/thankyou.html', :repo => repo
|
93
94
|
|
94
95
|
# >-------------------------------[ Routes ]--------------------------------<
|
data/recipes/views.rb
CHANGED
@@ -23,9 +23,11 @@ after_bundler do
|
|
23
23
|
if ['users_app','admin_app','subdomains_app'].include? prefs[:starter_app]
|
24
24
|
## INDEX
|
25
25
|
if prefer :starter_app, 'admin_app'
|
26
|
-
copy_from_repo 'app/views/users/index.html.erb', :
|
27
|
-
unless prefer :
|
28
|
-
copy_from_repo 'app/views/users/_user.html.erb'
|
26
|
+
copy_from_repo 'app/views/users/index-admin_app.html.erb', :prefs => 'admin_app'
|
27
|
+
unless prefer :form_builder, 'simple_form'
|
28
|
+
copy_from_repo 'app/views/users/_user.html.erb'
|
29
|
+
else
|
30
|
+
copy_from_repo 'app/views/users/_user-simple_form.html.erb', :prefs => 'simple_form'
|
29
31
|
end
|
30
32
|
else
|
31
33
|
copy_from_repo 'app/views/users/index.html.erb'
|
data/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rails_apps_composer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.2.
|
4
|
+
version: 2.2.18
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-
|
12
|
+
date: 2012-11-09 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: i18n
|
@@ -202,7 +202,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
202
202
|
version: '0'
|
203
203
|
segments:
|
204
204
|
- 0
|
205
|
-
hash: -
|
205
|
+
hash: -2188681930575705912
|
206
206
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
207
207
|
none: false
|
208
208
|
requirements:
|
@@ -211,7 +211,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
211
211
|
version: '0'
|
212
212
|
segments:
|
213
213
|
- 0
|
214
|
-
hash: -
|
214
|
+
hash: -2188681930575705912
|
215
215
|
requirements: []
|
216
216
|
rubyforge_project: rails_apps_composer
|
217
217
|
rubygems_version: 1.8.24
|