rails_apps_composer 3.0.18 → 3.0.19

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4df1af2afa0029ec54403a46b19ae1ad15fecb44
4
- data.tar.gz: 61439b4feec799cd43d9fdeef7474bdefae7eeb2
3
+ metadata.gz: 8b9fdd11f103be807a648de7806904ca4698fb05
4
+ data.tar.gz: b88ec2beb7db2e6d8e5abae820472b0fb08c2ca9
5
5
  SHA512:
6
- metadata.gz: 66036729f25cc78711230e547bf07aad188f686822683e8904731c758bb83fcc3f12f41c47b2dea2f452c98d93e33d9ee1c901b434a91a48a7162285ef45613c
7
- data.tar.gz: 46f97fb1380308756fd0acb0a9b9484a8ad5539b418317f6ae924bf40f85eb5817bd58e6272beaa678d9a6e6f2cee11e7633248b0c38702a3f24639a75abceba
6
+ metadata.gz: 01e0665d2e2b0e2200f514ffd27c529fc9de5e48c95c45cc2de4e2d6768076da8d7707935480fdebeceb3e0de4663b2e79172bc8b32cec9f3de6a615237ac7c3
7
+ data.tar.gz: b579074711e3d43b21ee7179f3581ac31fcddaceb61474f0799548501d21aa0e90ee6d2fb47a669146d290d66839ac9be2bc264c381e33de553b13c6ce6f00f8
@@ -21,43 +21,129 @@ if prefer :deployment, 'heroku'
21
21
  "name": "#{app_name.humanize.titleize}",
22
22
  "description": "Starter application generated by Rails Composer",
23
23
  "logo": "https://avatars3.githubusercontent.com/u/788200",
24
- "keywords": [
25
- "Ruby #{RUBY_VERSION}",
26
- "Rails #{Rails::VERSION::STRING}"
24
+ TEXT
25
+ end
26
+ append_file 'app.json', " \"repository\": \"https://github.com/RailsApps/#{prefs[:apps4]}\",\n" if prefs.keys.include?(:apps4)
27
+ append_file 'app.json', ' "keywords": [' + "\n"
28
+ append_file 'app.json', ' "Rails Composer",' + "\n"
29
+ append_file 'app.json', ' "RailsApps",' + "\n" + ' "starter",' + "\n" if prefs.keys.include?(:apps4)
30
+ append_file 'app.json', ' "RSpec",' + "\n" if prefer :tests, 'rspec'
31
+ append_file 'app.json', ' "Bootstrap",' + "\n" if prefer :frontend, 'bootstrap3'
32
+ append_file 'app.json', ' "Foundation",' + "\n" if prefer :frontend, 'pundit'
33
+ append_file 'app.json', ' "authentication",' + "\n" + ' "Devise",' + "\n" if prefer :authentication, 'devise'
34
+ append_file 'app.json', ' "authentication",' + "\n" + ' "OmniAuth",' + "\n" if prefer :authentication, 'omniauth'
35
+ append_file 'app.json', ' "authorization",' + "\n" + ' "roles",' + "\n" if prefer :authorization, 'roles'
36
+ append_file 'app.json', ' "authorization",' + "\n" + ' "Pundit",' + "\n" if prefer :authorization, 'pundit'
37
+ append_file 'app.json' do <<-TEXT
38
+ "Ruby",
39
+ "Rails"
27
40
  ],
28
41
  "scripts": {},
29
42
  "env": {
30
- "RAILS_ENV": "production",
31
- "ADMIN_EMAIL": {
32
- "description": "The administrator's email address.",
43
+ TEXT
44
+ end
45
+ case prefs[:email]
46
+ when 'gmail'
47
+ append_file 'app.json' do <<-TEXT
48
+ "GMAIL_USERNAME": {
49
+ "description": "Your Gmail address for sending mail.",
33
50
  "value": "user@example.com",
34
- "required": true
51
+ "required": false
35
52
  },
36
- "ADMIN_PASSWORD": {
37
- "description": "The administrator's password.",
53
+ "GMAIL_PASSWORD": {
54
+ "description": "Your Gmail password for sending mail.",
38
55
  "value": "changeme",
39
- "required": true
56
+ "required": false
40
57
  },
41
- "GMAIL_USERNAME": {
42
- "description": "Your Gmail address.",
58
+ TEXT
59
+ end
60
+ when 'sendgrid'
61
+ append_file 'app.json' do <<-TEXT
62
+ "SENDGRID_USERNAME": {
63
+ "description": "Your SendGrid address for sending mail.",
43
64
  "value": "user@example.com",
44
65
  "required": false
45
66
  },
46
- "GMAIL_PASSWORD": {
47
- "description": "Your Gmail password.",
67
+ "SENDGRID_PASSWORD": {
68
+ "description": "Your SendGrid password for sending mail.",
48
69
  "value": "changeme",
49
70
  "required": false
50
71
  },
51
- "OWNER_EMAIL": {
52
- "description": "Destination for messages sent from the app's contact form.",
72
+ TEXT
73
+ end
74
+ when 'mandrill'
75
+ append_file 'app.json' do <<-TEXT
76
+ "MANDRILL_USERNAME": {
77
+ "description": "Your Mandrill address for sending mail.",
53
78
  "value": "user@example.com",
54
79
  "required": false
55
80
  },
81
+ "MANDRILL_APIKEY": {
82
+ "description": "Your Mandrill API key for sending mail.",
83
+ "value": "changeme",
84
+ "required": false
85
+ },
86
+ TEXT
87
+ end
88
+ end
89
+ if prefer :authentication, 'omniauth'
90
+ append_file 'app.json' do <<-TEXT
91
+ "OMNIAUTH_PROVIDER_KEY": {
92
+ "description": "Credentials from Twitter, Facebook, or another provider.",
93
+ "value": "user@example.com",
94
+ "required": false
95
+ },
96
+ "OMNIAUTH_PROVIDER_SECRET": {
97
+ "description": "Credentials from Twitter, Facebook, or another provider.",
98
+ "value": "changeme",
99
+ "required": false
100
+ },
101
+ TEXT
102
+ end
103
+ end
104
+ if prefer :authentication, 'devise'
105
+ append_file 'app.json' do <<-TEXT
106
+ "ADMIN_EMAIL": {
107
+ "description": "The administrator's email address for signing in.",
108
+ "value": "user@example.com",
109
+ "required": true
110
+ },
111
+ "ADMIN_PASSWORD": {
112
+ "description": "The administrator's password for signing in.",
113
+ "value": "changeme",
114
+ "required": true
115
+ },
56
116
  "DOMAIN_NAME": {
57
- "description": "Required for sending mail. Use the app name you've given.",
117
+ "description": "Required for sending mail. Give an app name or use a custom domain.",
58
118
  "value": "myapp.herokuapp.com",
59
119
  "required": false
60
- }
120
+ },
121
+ TEXT
122
+ end
123
+ end
124
+ if prefer :apps4, 'learn-rails'
125
+ append_file 'app.json' do <<-TEXT
126
+ "OWNER_EMAIL": {
127
+ "description": "Destination for messages sent from the application's contact form.",
128
+ "value": "user@example.com",
129
+ "required": false
130
+ },
131
+ TEXT
132
+ end
133
+ end
134
+ if (!prefs[:secrets].nil?)
135
+ prefs[:secrets].each do |secret|
136
+ append_file 'app.json' do <<-TEXT
137
+ "#{secret.upcase}": {
138
+ "description": "no description",
139
+ "required": false
140
+ },
141
+ TEXT
142
+ end
143
+ end
144
+ end
145
+ append_file 'app.json' do <<-TEXT
146
+ "RAILS_ENV": "production"
61
147
  }
62
148
  }
63
149
  TEXT
data/recipes/gems.rb CHANGED
@@ -223,7 +223,7 @@ stage_two do
223
223
  end
224
224
  ## Figaro Gem
225
225
  if prefer :local_env_file, 'figaro'
226
- generate 'figaro:install'
226
+ run 'figaro install'
227
227
  gsub_file 'config/application.yml', /# PUSHER_.*\n/, ''
228
228
  gsub_file 'config/application.yml', /# STRIPE_.*\n/, ''
229
229
  prepend_to_file 'config/application.yml' do <<-FILE
data/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module RailsWizard
2
- VERSION = "3.0.18"
2
+ VERSION = "3.0.19"
3
3
  end
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: 3.0.18
4
+ version: 3.0.19
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Kehoe
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-09-23 00:00:00.000000000 Z
11
+ date: 2014-09-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: i18n