ajmalafif-suspenders 1.18.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +4 -0
- data/.ruby-version +1 -0
- data/.travis.yml +11 -0
- data/CONTRIBUTING.md +36 -0
- data/Gemfile +3 -0
- data/Gemfile.lock +135 -0
- data/LICENSE +21 -0
- data/NEWS.md +292 -0
- data/README.md +190 -0
- data/Rakefile +8 -0
- data/bin/rake +16 -0
- data/bin/rspec +16 -0
- data/bin/setup +13 -0
- data/bin/suspenders +18 -0
- data/lib/suspenders.rb +4 -0
- data/lib/suspenders/actions.rb +25 -0
- data/lib/suspenders/app_builder.rb +398 -0
- data/lib/suspenders/generators/app_generator.rb +215 -0
- data/lib/suspenders/version.rb +5 -0
- data/spec/fakes/bin/heroku +5 -0
- data/spec/fakes/bin/hub +5 -0
- data/spec/features/github_spec.rb +10 -0
- data/spec/features/heroku_spec.rb +19 -0
- data/spec/features/new_project_spec.rb +117 -0
- data/spec/spec_helper.rb +24 -0
- data/spec/support/fake_github.rb +21 -0
- data/spec/support/fake_heroku.rb +38 -0
- data/spec/support/suspenders.rb +49 -0
- data/suspenders.gemspec +38 -0
- data/templates/Gemfile.erb +52 -0
- data/templates/Procfile +2 -0
- data/templates/README.md.erb +35 -0
- data/templates/_analytics.html.erb +7 -0
- data/templates/_flashes.html.erb +7 -0
- data/templates/_javascript.html.erb +12 -0
- data/templates/action_mailer.rb +5 -0
- data/templates/application.css.scss +7 -0
- data/templates/background_jobs_rspec.rb +19 -0
- data/templates/bin_setup.erb +34 -0
- data/templates/config_i18n_tasks.yml +13 -0
- data/templates/config_locales_en.yml.erb +19 -0
- data/templates/database_cleaner_rspec.rb +21 -0
- data/templates/development_seeds.rb +12 -0
- data/templates/disable_xml_params.rb +3 -0
- data/templates/errors.rb +34 -0
- data/templates/factory_girl_rspec.rb +3 -0
- data/templates/i18n.rb +3 -0
- data/templates/newrelic.yml.erb +34 -0
- data/templates/postgresql_database.yml.erb +12 -0
- data/templates/rack_timeout.rb +1 -0
- data/templates/rails_helper.rb +23 -0
- data/templates/sample.env +3 -0
- data/templates/secrets.yml +14 -0
- data/templates/smtp.rb +9 -0
- data/templates/spec_helper.rb +16 -0
- data/templates/staging.rb +5 -0
- data/templates/suspenders_gitignore +17 -0
- data/templates/suspenders_layout.html.erb.erb +16 -0
- data/templates/travis.yml.erb +24 -0
- data/templates/unicorn.rb +30 -0
- metadata +223 -0
@@ -0,0 +1 @@
|
|
1
|
+
Rack::Timeout.timeout = (ENV["TIMEOUT_IN_SECONDS"] || 5).to_i
|
@@ -0,0 +1,23 @@
|
|
1
|
+
ENV["RAILS_ENV"] = "test"
|
2
|
+
|
3
|
+
require File.expand_path("../../config/environment", __FILE__)
|
4
|
+
|
5
|
+
require "rspec/rails"
|
6
|
+
require "shoulda/matchers"
|
7
|
+
|
8
|
+
Dir[Rails.root.join("spec/support/**/*.rb")].each { |file| require file }
|
9
|
+
|
10
|
+
module Features
|
11
|
+
# Extend this module in spec/support/features/*.rb
|
12
|
+
include Formulaic::Dsl
|
13
|
+
end
|
14
|
+
|
15
|
+
RSpec.configure do |config|
|
16
|
+
config.include Features, type: :feature
|
17
|
+
config.infer_base_class_for_anonymous_controllers = false
|
18
|
+
config.infer_spec_type_from_file_location!
|
19
|
+
config.use_transactional_fixtures = false
|
20
|
+
end
|
21
|
+
|
22
|
+
ActiveRecord::Migration.maintain_test_schema!
|
23
|
+
Capybara.javascript_driver = :webkit
|
data/templates/smtp.rb
ADDED
@@ -0,0 +1,9 @@
|
|
1
|
+
SMTP_SETTINGS = {
|
2
|
+
address: ENV.fetch("SMTP_ADDRESS"), # example: "smtp.sendgrid.net"
|
3
|
+
authentication: :plain,
|
4
|
+
domain: ENV.fetch("SMTP_DOMAIN"), # example: "this-app.com"
|
5
|
+
enable_starttls_auto: true,
|
6
|
+
password: ENV.fetch("SMTP_PASSWORD"),
|
7
|
+
port: "587",
|
8
|
+
user_name: ENV.fetch("SMTP_USERNAME")
|
9
|
+
}
|
@@ -0,0 +1,16 @@
|
|
1
|
+
require "webmock/rspec"
|
2
|
+
|
3
|
+
# http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
|
4
|
+
RSpec.configure do |config|
|
5
|
+
config.expect_with :rspec do |expectations|
|
6
|
+
expectations.syntax = :expect
|
7
|
+
end
|
8
|
+
|
9
|
+
config.mock_with :rspec do |mocks|
|
10
|
+
mocks.syntax = :expect
|
11
|
+
end
|
12
|
+
|
13
|
+
config.order = :random
|
14
|
+
end
|
15
|
+
|
16
|
+
WebMock.disable_net_connect!(allow_localhost: true)
|
@@ -0,0 +1,16 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<meta charset="utf-8" />
|
5
|
+
<meta name="ROBOTS" content="NOODP" />
|
6
|
+
<meta name="viewport" content="initial-scale=1" />
|
7
|
+
<title><%%= title %></title>
|
8
|
+
<%%= stylesheet_link_tag :application, media: "all" %>
|
9
|
+
<%%= csrf_meta_tags %>
|
10
|
+
</head>
|
11
|
+
<body class="<%%= body_class %>">
|
12
|
+
<%%= render "flashes" -%>
|
13
|
+
<%%= yield %>
|
14
|
+
<%%= render "javascript" %>
|
15
|
+
</body>
|
16
|
+
</html>
|
@@ -0,0 +1,24 @@
|
|
1
|
+
before_install:
|
2
|
+
- "echo '--colour' > ~/.rspec"
|
3
|
+
- "echo 'gem: --no-document' > ~/.gemrc"
|
4
|
+
- export DISPLAY=:99.0
|
5
|
+
- sh -e /etc/init.d/xvfb start
|
6
|
+
before_script:
|
7
|
+
- cp .sample.env .env
|
8
|
+
<% if options[:database] == "postgresql" %>
|
9
|
+
- psql -c 'create database "<%= app_name %>_test";' -U postgres
|
10
|
+
<% end %>
|
11
|
+
branches:
|
12
|
+
only:
|
13
|
+
- master
|
14
|
+
cache:
|
15
|
+
- bundler
|
16
|
+
language:
|
17
|
+
- ruby
|
18
|
+
notifications:
|
19
|
+
email:
|
20
|
+
- false
|
21
|
+
rvm:
|
22
|
+
- <%= Suspenders::RUBY_VERSION %>
|
23
|
+
addons:
|
24
|
+
postgresql: "9.3"
|
@@ -0,0 +1,30 @@
|
|
1
|
+
# https://devcenter.heroku.com/articles/rails-unicorn
|
2
|
+
|
3
|
+
worker_processes (ENV["WEB_CONCURRENCY"] || 3).to_i
|
4
|
+
timeout (ENV["WEB_TIMEOUT"] || 5).to_i
|
5
|
+
preload_app true
|
6
|
+
|
7
|
+
before_fork do |server, worker|
|
8
|
+
Signal.trap "TERM" do
|
9
|
+
puts "Unicorn master intercepting TERM and sending myself QUIT instead"
|
10
|
+
Process.kill "QUIT", Process.pid
|
11
|
+
end
|
12
|
+
|
13
|
+
if defined? ActiveRecord::Base
|
14
|
+
ActiveRecord::Base.connection.disconnect!
|
15
|
+
end
|
16
|
+
end
|
17
|
+
|
18
|
+
after_fork do |server, worker|
|
19
|
+
Signal.trap "TERM" do
|
20
|
+
puts "Unicorn worker intercepting TERM and doing nothing. Wait for master to send QUIT"
|
21
|
+
end
|
22
|
+
|
23
|
+
if defined? ActiveRecord::Base
|
24
|
+
config = ActiveRecord::Base.configurations[Rails.env] ||
|
25
|
+
Rails.application.config.database_configuration[Rails.env]
|
26
|
+
config["reaping_frequency"] = (ENV["DB_REAPING_FREQUENCY"] || 10).to_i
|
27
|
+
config["pool"] = (ENV["DB_POOL"] || 2).to_i
|
28
|
+
ActiveRecord::Base.establish_connection(config)
|
29
|
+
end
|
30
|
+
end
|
metadata
ADDED
@@ -0,0 +1,223 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: ajmalafif-suspenders
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 1.18.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- thoughtbot
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2014-11-14 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bitters
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 0.10.0
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: 0.10.0
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: bundler
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '1.3'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '1.3'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rails
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - '='
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: 4.1.8
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - '='
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: 4.1.8
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: aruba
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0.5'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0.5'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: cucumber
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '1.2'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '1.2'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: rspec
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '2.0'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '2.0'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: capybara
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - "~>"
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '2.2'
|
104
|
+
- - ">="
|
105
|
+
- !ruby/object:Gem::Version
|
106
|
+
version: 2.2.0
|
107
|
+
type: :development
|
108
|
+
prerelease: false
|
109
|
+
version_requirements: !ruby/object:Gem::Requirement
|
110
|
+
requirements:
|
111
|
+
- - "~>"
|
112
|
+
- !ruby/object:Gem::Version
|
113
|
+
version: '2.2'
|
114
|
+
- - ">="
|
115
|
+
- !ruby/object:Gem::Version
|
116
|
+
version: 2.2.0
|
117
|
+
description: |
|
118
|
+
Suspenders is a base Rails project that you can upgrade. It is used by
|
119
|
+
thoughtbot to get a jump start on a working app. Use Suspenders if you're in a
|
120
|
+
rush to build something amazing; don't use it if you like missing deadlines.
|
121
|
+
email: support@thoughtbot.com
|
122
|
+
executables:
|
123
|
+
- suspenders
|
124
|
+
extensions: []
|
125
|
+
extra_rdoc_files:
|
126
|
+
- README.md
|
127
|
+
- LICENSE
|
128
|
+
files:
|
129
|
+
- ".gitignore"
|
130
|
+
- ".ruby-version"
|
131
|
+
- ".travis.yml"
|
132
|
+
- CONTRIBUTING.md
|
133
|
+
- Gemfile
|
134
|
+
- Gemfile.lock
|
135
|
+
- LICENSE
|
136
|
+
- NEWS.md
|
137
|
+
- README.md
|
138
|
+
- Rakefile
|
139
|
+
- bin/rake
|
140
|
+
- bin/rspec
|
141
|
+
- bin/setup
|
142
|
+
- bin/suspenders
|
143
|
+
- lib/suspenders.rb
|
144
|
+
- lib/suspenders/actions.rb
|
145
|
+
- lib/suspenders/app_builder.rb
|
146
|
+
- lib/suspenders/generators/app_generator.rb
|
147
|
+
- lib/suspenders/version.rb
|
148
|
+
- spec/fakes/bin/heroku
|
149
|
+
- spec/fakes/bin/hub
|
150
|
+
- spec/features/github_spec.rb
|
151
|
+
- spec/features/heroku_spec.rb
|
152
|
+
- spec/features/new_project_spec.rb
|
153
|
+
- spec/spec_helper.rb
|
154
|
+
- spec/support/fake_github.rb
|
155
|
+
- spec/support/fake_heroku.rb
|
156
|
+
- spec/support/suspenders.rb
|
157
|
+
- suspenders.gemspec
|
158
|
+
- templates/Gemfile.erb
|
159
|
+
- templates/Procfile
|
160
|
+
- templates/README.md.erb
|
161
|
+
- templates/_analytics.html.erb
|
162
|
+
- templates/_flashes.html.erb
|
163
|
+
- templates/_javascript.html.erb
|
164
|
+
- templates/action_mailer.rb
|
165
|
+
- templates/application.css.scss
|
166
|
+
- templates/background_jobs_rspec.rb
|
167
|
+
- templates/bin_setup.erb
|
168
|
+
- templates/config_i18n_tasks.yml
|
169
|
+
- templates/config_locales_en.yml.erb
|
170
|
+
- templates/database_cleaner_rspec.rb
|
171
|
+
- templates/development_seeds.rb
|
172
|
+
- templates/disable_xml_params.rb
|
173
|
+
- templates/errors.rb
|
174
|
+
- templates/factory_girl_rspec.rb
|
175
|
+
- templates/i18n.rb
|
176
|
+
- templates/newrelic.yml.erb
|
177
|
+
- templates/postgresql_database.yml.erb
|
178
|
+
- templates/rack_timeout.rb
|
179
|
+
- templates/rails_helper.rb
|
180
|
+
- templates/sample.env
|
181
|
+
- templates/secrets.yml
|
182
|
+
- templates/smtp.rb
|
183
|
+
- templates/spec_helper.rb
|
184
|
+
- templates/staging.rb
|
185
|
+
- templates/suspenders_gitignore
|
186
|
+
- templates/suspenders_layout.html.erb.erb
|
187
|
+
- templates/travis.yml.erb
|
188
|
+
- templates/unicorn.rb
|
189
|
+
homepage: http://github.com/ajmalafif/suspenders
|
190
|
+
licenses:
|
191
|
+
- MIT
|
192
|
+
metadata: {}
|
193
|
+
post_install_message:
|
194
|
+
rdoc_options:
|
195
|
+
- "--charset=UTF-8"
|
196
|
+
require_paths:
|
197
|
+
- lib
|
198
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
199
|
+
requirements:
|
200
|
+
- - ">="
|
201
|
+
- !ruby/object:Gem::Version
|
202
|
+
version: 2.1.4
|
203
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
204
|
+
requirements:
|
205
|
+
- - ">="
|
206
|
+
- !ruby/object:Gem::Version
|
207
|
+
version: '0'
|
208
|
+
requirements: []
|
209
|
+
rubyforge_project:
|
210
|
+
rubygems_version: 2.4.3
|
211
|
+
signing_key:
|
212
|
+
specification_version: 4
|
213
|
+
summary: Generate a Rails app using thoughtbot's best practices.
|
214
|
+
test_files:
|
215
|
+
- spec/fakes/bin/heroku
|
216
|
+
- spec/fakes/bin/hub
|
217
|
+
- spec/features/github_spec.rb
|
218
|
+
- spec/features/heroku_spec.rb
|
219
|
+
- spec/features/new_project_spec.rb
|
220
|
+
- spec/spec_helper.rb
|
221
|
+
- spec/support/fake_github.rb
|
222
|
+
- spec/support/fake_heroku.rb
|
223
|
+
- spec/support/suspenders.rb
|