rails_apps_composer 2.4.12 → 2.4.13
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/rails_wizard/command.rb +1 -1
- data/recipes/apps4.rb +4 -2
- data/recipes/frontend.rb +17 -12
- data/recipes/git.rb +6 -0
- data/recipes/models.rb +1 -1
- data/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3184151973897b1c0e19e832f24a9728e968cf95
|
4
|
+
data.tar.gz: f12186da396c2f6b7cfbe4263a67ad7b1cc378ac
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b05c9eaefa0ad3d39ac314e1be4efd1724a25e2c5c037ecbe4157cf5f53c50f88b95fbef217626a761f356225d1a8fb47ecc321493f24ef18df8d7ea71d7b5e0
|
7
|
+
data.tar.gz: 31b0a3b148e7d50d196381d8726a32f51f024c432581641905cfe877f75813ef4c2580add7e5ff8cc719c1b678fff50b1b2120151763d95ee64ac7a647f46081
|
data/lib/rails_wizard/command.rb
CHANGED
@@ -67,7 +67,7 @@ module RailsWizard
|
|
67
67
|
# Load defaults from a file; if a file specifies recipes, they'll be run *before*
|
68
68
|
# any on the command line (or prompted for)..
|
69
69
|
return [[], {}] unless options[:defaults]
|
70
|
-
defaults =
|
70
|
+
defaults = Kernel.open(options[:defaults]) {|f| YAML.load(f) }
|
71
71
|
recipes = defaults.delete('recipes') { [] }
|
72
72
|
[recipes, defaults]
|
73
73
|
end
|
data/recipes/apps4.rb
CHANGED
@@ -61,7 +61,8 @@ if prefer :apps4, 'learn-rails'
|
|
61
61
|
copy_from_repo 'app/views/user_mailer/contact_email.html.erb', :repo => repo
|
62
62
|
copy_from_repo 'app/views/user_mailer/contact_email.text.erb', :repo => repo
|
63
63
|
copy_from_repo 'app/views/visitors/new.html.erb', :repo => repo
|
64
|
-
|
64
|
+
# create navigation links using the rails_layout gem
|
65
|
+
generate 'navigation -f'
|
65
66
|
|
66
67
|
# >-------------------------------[ Routes ]--------------------------------<
|
67
68
|
|
@@ -121,7 +122,8 @@ if prefer :apps4, 'rails-bootstrap'
|
|
121
122
|
|
122
123
|
copy_from_repo 'app/views/pages/about.html.erb', :repo => repo
|
123
124
|
copy_from_repo 'app/views/visitors/new.html.erb', :repo => repo
|
124
|
-
|
125
|
+
# create navigation links using the rails_layout gem
|
126
|
+
generate 'navigation -f'
|
125
127
|
|
126
128
|
# >-------------------------------[ Routes ]--------------------------------<
|
127
129
|
|
data/recipes/frontend.rb
CHANGED
@@ -15,24 +15,29 @@ after_bundler do
|
|
15
15
|
generate 'layout foundation4 -f'
|
16
16
|
end
|
17
17
|
|
18
|
-
|
19
|
-
if prefer :
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
18
|
+
### GIT ###
|
19
|
+
git :add => '-A' if prefer :git, true
|
20
|
+
git :commit => '-qm "rails_apps_composer: front-end framework"' if prefer :git, true
|
21
|
+
end # after_bundler
|
22
|
+
|
23
|
+
after_everything do
|
24
|
+
say_wizard "recipe running after everything"
|
25
|
+
# create navigation links using the rails_layout gem
|
26
|
+
generate 'navigation -f'
|
27
|
+
# replace with specialized navigation partials
|
28
|
+
if prefer :authentication, 'omniauth'
|
29
|
+
if prefer :authorization, 'cancan'
|
30
|
+
copy_from 'https://raw.github.com/RailsApps/rails-composer/master/files/app/views/layouts/_navigation-cancan-omniauth.html.erb', 'app/views/layouts/_navigation.html.erb'
|
31
|
+
else
|
32
|
+
copy_from_repo 'app/views/layouts/_navigation-omniauth.html.erb', :prefs => 'omniauth'
|
25
33
|
end
|
26
|
-
else
|
27
|
-
copy_from_repo 'app/views/layouts/_navigation-devise.html.erb', :prefs => 'devise'
|
28
|
-
copy_from_repo 'app/views/layouts/_navigation-omniauth.html.erb', :prefs => 'omniauth'
|
29
34
|
end
|
30
35
|
copy_from_repo 'app/views/layouts/_navigation-subdomains_app.html.erb', :prefs => 'subdomains_app'
|
31
36
|
|
32
37
|
### GIT ###
|
33
38
|
git :add => '-A' if prefer :git, true
|
34
|
-
git :commit => '-qm "rails_apps_composer:
|
35
|
-
end #
|
39
|
+
git :commit => '-qm "rails_apps_composer: navigation links"' if prefer :git, true
|
40
|
+
end # after_everything
|
36
41
|
|
37
42
|
__END__
|
38
43
|
|
data/recipes/git.rb
CHANGED
@@ -9,6 +9,12 @@ if prefer :git, true
|
|
9
9
|
git :init
|
10
10
|
git :add => '-A'
|
11
11
|
git :commit => '-qm "rails_apps_composer: initial commit"'
|
12
|
+
else
|
13
|
+
after_everything do
|
14
|
+
say_wizard "removing .gitignore and .gitkeep files"
|
15
|
+
git_files = Dir[File.join('**','.gitkeep')] + Dir[File.join('**','.gitignore')]
|
16
|
+
File.unlink git_files
|
17
|
+
end
|
12
18
|
end
|
13
19
|
|
14
20
|
__END__
|
data/recipes/models.rb
CHANGED
@@ -12,7 +12,7 @@ after_bundler do
|
|
12
12
|
generate 'devise user' # create the User model
|
13
13
|
if prefer :orm, 'mongoid'
|
14
14
|
## DEVISE AND MONGOID
|
15
|
-
copy_from_repo 'app/models/user.rb', :repo => 'https://raw.github.com/RailsApps/rails3-mongoid-devise/master/'
|
15
|
+
copy_from_repo 'app/models/user.rb', :repo => 'https://raw.github.com/RailsApps/rails3-mongoid-devise/master/' unless rails_4?
|
16
16
|
if (prefer :devise_modules, 'confirmable') || (prefer :devise_modules, 'invitable')
|
17
17
|
gsub_file 'app/models/user.rb', /:registerable,/, ":registerable, :confirmable,"
|
18
18
|
gsub_file 'app/models/user.rb', /# field :confirmation_token/, "field :confirmation_token"
|
data/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rails_apps_composer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.4.
|
4
|
+
version: 2.4.13
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Kehoe
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-11-
|
11
|
+
date: 2013-11-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: i18n
|
@@ -192,7 +192,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
192
192
|
version: '0'
|
193
193
|
requirements: []
|
194
194
|
rubyforge_project: rails_apps_composer
|
195
|
-
rubygems_version: 2.
|
195
|
+
rubygems_version: 2.1.10
|
196
196
|
signing_key:
|
197
197
|
specification_version: 4
|
198
198
|
summary: A version of the RailsWizard gem with custom recipes for Rails starter apps.
|