railslove-suspenders 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
data/.travis.yml CHANGED
@@ -2,5 +2,7 @@ language: ruby
2
2
  rvm:
3
3
  - 1.9.3
4
4
  - 2.0.0
5
+ install:
6
+ - bundle install
5
7
  notifications:
6
8
  email: false
data/Gemfile.lock CHANGED
@@ -1,88 +1,100 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- railslove-suspenders (0.1.0)
4
+ railslove-suspenders (0.1.1)
5
5
  bundler (~> 1.3)
6
- hub (~> 1.10)
7
- rails (= 3.2.13)
6
+ rails (= 4.0.0)
8
7
 
9
8
  GEM
10
9
  remote: https://rubygems.org/
11
10
  specs:
12
- actionmailer (3.2.13)
13
- actionpack (= 3.2.13)
11
+ actionmailer (4.0.0)
12
+ actionpack (= 4.0.0)
14
13
  mail (~> 2.5.3)
15
- actionpack (3.2.13)
16
- activemodel (= 3.2.13)
17
- activesupport (= 3.2.13)
18
- builder (~> 3.0.0)
14
+ actionpack (4.0.0)
15
+ activesupport (= 4.0.0)
16
+ builder (~> 3.1.0)
19
17
  erubis (~> 2.7.0)
20
- journey (~> 1.0.4)
21
- rack (~> 1.4.5)
22
- rack-cache (~> 1.2)
23
- rack-test (~> 0.6.1)
24
- sprockets (~> 2.2.1)
25
- activemodel (3.2.13)
26
- activesupport (= 3.2.13)
27
- builder (~> 3.0.0)
28
- activerecord (3.2.13)
29
- activemodel (= 3.2.13)
30
- activesupport (= 3.2.13)
31
- arel (~> 3.0.2)
32
- tzinfo (~> 0.3.29)
33
- activeresource (3.2.13)
34
- activemodel (= 3.2.13)
35
- activesupport (= 3.2.13)
36
- activesupport (3.2.13)
37
- i18n (= 0.6.1)
38
- multi_json (~> 1.0)
39
- arel (3.0.2)
40
- builder (3.0.4)
18
+ rack (~> 1.5.2)
19
+ rack-test (~> 0.6.2)
20
+ activemodel (4.0.0)
21
+ activesupport (= 4.0.0)
22
+ builder (~> 3.1.0)
23
+ activerecord (4.0.0)
24
+ activemodel (= 4.0.0)
25
+ activerecord-deprecated_finders (~> 1.0.2)
26
+ activesupport (= 4.0.0)
27
+ arel (~> 4.0.0)
28
+ activerecord-deprecated_finders (1.0.3)
29
+ activesupport (4.0.0)
30
+ i18n (~> 0.6, >= 0.6.4)
31
+ minitest (~> 4.2)
32
+ multi_json (~> 1.3)
33
+ thread_safe (~> 0.1)
34
+ tzinfo (~> 0.3.37)
35
+ arel (4.0.0)
36
+ aruba (0.5.3)
37
+ childprocess (>= 0.3.6)
38
+ cucumber (>= 1.1.1)
39
+ rspec-expectations (>= 2.7.0)
40
+ atomic (1.1.14)
41
+ builder (3.1.4)
42
+ childprocess (0.3.9)
43
+ ffi (~> 1.0, >= 1.0.11)
44
+ cucumber (1.3.8)
45
+ builder (>= 2.1.2)
46
+ diff-lcs (>= 1.1.3)
47
+ gherkin (~> 2.12.1)
48
+ multi_json (>= 1.7.5, < 2.0)
49
+ multi_test (>= 0.0.2)
50
+ diff-lcs (1.2.4)
41
51
  erubis (2.7.0)
52
+ ffi (1.9.0)
53
+ gherkin (2.12.1)
54
+ multi_json (~> 1.3)
42
55
  hike (1.2.3)
43
- hub (1.10.6)
44
- i18n (0.6.1)
45
- journey (1.0.4)
46
- json (1.8.0)
56
+ i18n (0.6.5)
47
57
  mail (2.5.4)
48
58
  mime-types (~> 1.16)
49
59
  treetop (~> 1.4.8)
50
- mime-types (1.23)
51
- multi_json (1.7.6)
60
+ mime-types (1.25)
61
+ minitest (4.7.5)
62
+ multi_json (1.8.0)
63
+ multi_test (0.0.2)
52
64
  polyglot (0.3.3)
53
- rack (1.4.5)
54
- rack-cache (1.2)
55
- rack (>= 0.4)
56
- rack-ssl (1.3.3)
57
- rack
65
+ rack (1.5.2)
58
66
  rack-test (0.6.2)
59
67
  rack (>= 1.0)
60
- rails (3.2.13)
61
- actionmailer (= 3.2.13)
62
- actionpack (= 3.2.13)
63
- activerecord (= 3.2.13)
64
- activeresource (= 3.2.13)
65
- activesupport (= 3.2.13)
66
- bundler (~> 1.0)
67
- railties (= 3.2.13)
68
- railties (3.2.13)
69
- actionpack (= 3.2.13)
70
- activesupport (= 3.2.13)
71
- rack-ssl (~> 1.3.2)
68
+ rails (4.0.0)
69
+ actionmailer (= 4.0.0)
70
+ actionpack (= 4.0.0)
71
+ activerecord (= 4.0.0)
72
+ activesupport (= 4.0.0)
73
+ bundler (>= 1.3.0, < 2.0)
74
+ railties (= 4.0.0)
75
+ sprockets-rails (~> 2.0.0)
76
+ railties (4.0.0)
77
+ actionpack (= 4.0.0)
78
+ activesupport (= 4.0.0)
72
79
  rake (>= 0.8.7)
73
- rdoc (~> 3.4)
74
- thor (>= 0.14.6, < 2.0)
75
- rake (10.0.4)
76
- rdoc (3.12.2)
77
- json (~> 1.4)
78
- sprockets (2.2.2)
80
+ thor (>= 0.18.1, < 2.0)
81
+ rake (10.1.0)
82
+ rspec-expectations (2.14.2)
83
+ diff-lcs (>= 1.1.3, < 2.0)
84
+ sprockets (2.10.0)
79
85
  hike (~> 1.2)
80
86
  multi_json (~> 1.0)
81
87
  rack (~> 1.0)
82
88
  tilt (~> 1.1, != 1.3.0)
89
+ sprockets-rails (2.0.0)
90
+ actionpack (>= 3.0)
91
+ activesupport (>= 3.0)
92
+ sprockets (~> 2.8)
83
93
  thor (0.18.1)
94
+ thread_safe (0.1.3)
95
+ atomic
84
96
  tilt (1.4.1)
85
- treetop (1.4.14)
97
+ treetop (1.4.15)
86
98
  polyglot
87
99
  polyglot (>= 0.3.1)
88
100
  tzinfo (0.3.37)
@@ -91,4 +103,6 @@ PLATFORMS
91
103
  ruby
92
104
 
93
105
  DEPENDENCIES
106
+ aruba (~> 0.5)
107
+ cucumber (~> 1.2)
94
108
  railslove-suspenders!
data/README.md CHANGED
@@ -34,12 +34,12 @@ It includes application gems like:
34
34
 
35
35
  And testing gems like:
36
36
 
37
- * [Mocha](https://github.com/freerange/mocha) for stubbing and spying
38
37
  * [Capybara](https://github.com/jnicklas/capybara) and
39
38
  [Capybara Webkit](https://github.com/thoughtbot/capybara-webkit) for
40
39
  integration testing
41
40
  * [Factory Girl](https://github.com/thoughtbot/factory_girl) for test data
42
41
  * [RSpec](https://github.com/rspec/rspec) for unit testing
42
+ * [RSpec Mocks](https://github.com/rspec/rspec-mocks) for stubbing and spying
43
43
  * [Shoulda Matchers](https://github.com/thoughtbot/shoulda-matchers) for common
44
44
  RSpec matchers
45
45
  * [Timecop](https://github.com/jtrupiano/timecop-console) for testing time
@@ -52,8 +52,8 @@ Suspenders also comes with:
52
52
  * Override recipient emails in staging environment.
53
53
  * Rails' flashes set up and in application layout.
54
54
  * A few nice time formats set up for localization.
55
- * [Heroku-recommended asset pipeline
56
- settings](https://devcenter.heroku.com/articles/rails3x-asset-pipeline-cedar/).
55
+ * [Heroku-recommended
56
+ settings](https://devcenter.heroku.com/articles/rails4-getting-started).
57
57
 
58
58
  Heroku
59
59
  ------
@@ -70,7 +70,10 @@ This has the same effect as running:
70
70
  Github
71
71
  ------
72
72
 
73
- You can optionally create a Github repository:
73
+ You can optionally create a Github repository for the suspended Rails app. It
74
+ requires that you have [Hub](https://github.com/github/hub) on your system:
75
+
76
+ curl http://hub.github.com/standalone -sLo ~/bin/hub && chmod +x ~/bin/hub
74
77
 
75
78
  suspenders app --github organization/project
76
79
 
@@ -24,12 +24,12 @@ When 'I ensure no databases exist for "$project_name"' do |project_name|
24
24
  end
25
25
 
26
26
  When 'I suspend a project called "$project_name"' do |project_name|
27
- suspenders_bin = File.expand_path(File.join('..', '..', 'bin', 'suspenders'), File.dirname(__FILE__))
27
+ suspenders_bin = File.expand_path(File.join('..', '..', 'bin', 'railslove-suspenders'), File.dirname(__FILE__))
28
28
  run_simple "#{suspenders_bin} #{project_name}"
29
29
  end
30
30
 
31
- When /^I suspend a project called "([^"]*)" with:$/ do |project_name, arguments_table|
32
- suspenders_bin = File.expand_path(File.join('..', '..', 'bin', 'suspenders'), File.dirname(__FILE__))
31
+ When %r{I suspend a project called "([^"]*)" with:} do |project_name, arguments_table|
32
+ suspenders_bin = File.expand_path(File.join('..', '..', 'bin', 'railslove-suspenders'), File.dirname(__FILE__))
33
33
  arguments = arguments_table.hashes.inject([]) do |accum, argument|
34
34
  accum << "#{argument['argument']}=#{argument['value']}"
35
35
  end.join
@@ -49,20 +49,20 @@ Then 'I can cleanly rake the project' do
49
49
  }
50
50
  end
51
51
 
52
- Then /^"(.*)" should not be installed$/ do |gem_name|
52
+ Then %r{"(.*)" should not be installed} do |gem_name|
53
53
  in_current_dir do
54
54
  system("bundle show #{gem_name} 2>&1 > /dev/null").should be_false
55
55
  end
56
56
  end
57
57
 
58
- Then /^"(.*)" should not be included in "(.*)"$/ do |content, file_path|
58
+ Then %r{"(.*)" should not be included in "(.*)"} do |content, file_path|
59
59
  check_file_content file_path, content, false
60
60
  end
61
61
 
62
- Then /^the "([^"]*)" Heroku app should exist$/ do |app_name|
62
+ Then %r{the "([^"]*)" Heroku app should exist} do |app_name|
63
63
  FakeHeroku.should have_created_app(app_name)
64
64
  end
65
65
 
66
- Then /^the "([^"]*)" Github repo should exist$/ do |repo_name|
66
+ Then %r{the "([^"]*)" Github repo should exist} do |repo_name|
67
67
  FakeGithub.should have_created_repo(repo_name)
68
- end
68
+ end
@@ -61,12 +61,6 @@ module RailsloveSuspenders
61
61
  # "Mail.register_interceptor RecipientInterceptor.new(ENV['EMAIL_RECIPIENTS'])\n"
62
62
  end
63
63
 
64
- def initialize_on_precompile
65
- inject_into_file 'config/application.rb',
66
- "\n config.assets.initialize_on_precompile = false",
67
- :after => 'config.assets.enabled = true'
68
- end
69
-
70
64
  def create_partials_directory
71
65
  empty_directory 'app/assets/stylesheets/base'
72
66
  empty_directory 'app/assets/stylesheets/modules'
@@ -106,11 +100,6 @@ module RailsloveSuspenders
106
100
  directory 'javascripts', 'app/assets/javascripts'
107
101
  end
108
102
 
109
- def add_jquery_ui
110
- inject_into_file 'app/assets/javascripts/application.js',
111
- "//= require jquery-ui\n", :before => '//= require_tree .'
112
- end
113
-
114
103
  def use_postgres_config_template
115
104
  template 'postgresql_database.yml.erb', 'config/database.yml',
116
105
  :force => true
@@ -141,11 +130,6 @@ module RailsloveSuspenders
141
130
  def configure_rspec
142
131
  remove_file '.rspec'
143
132
  copy_file 'rspec', '.rspec'
144
- prepend_file 'spec/spec_helper.rb', simplecov_init
145
-
146
- replace_in_file 'spec/spec_helper.rb',
147
- '# config.mock_with :mocha',
148
- 'config.mock_with :mocha'
149
133
 
150
134
  rspec_expect_syntax = <<-RUBY
151
135
 
@@ -205,7 +189,7 @@ module RailsloveSuspenders
205
189
 
206
190
  def configure_capybara_webkit
207
191
  append_file 'spec/spec_helper.rb' do
208
- "\nCapybara.javascript_driver = :webkit"
192
+ "\nCapybara.javascript_driver = :webkit\n"
209
193
  end
210
194
  end
211
195
 
@@ -231,14 +215,7 @@ module RailsloveSuspenders
231
215
  def gitignore_files
232
216
  concat_file 'suspenders_gitignore', '.gitignore'
233
217
  [
234
- 'app/models',
235
- 'app/assets/images',
236
- 'db/migrate',
237
- 'log',
238
- 'spec/support',
239
218
  'spec/lib',
240
- 'spec/models',
241
- 'spec/views',
242
219
  'spec/controllers',
243
220
  'spec/helpers',
244
221
  'spec/support/matchers',
@@ -246,7 +223,7 @@ module RailsloveSuspenders
246
223
  'spec/support/shared_examples'
247
224
  ].each do |dir|
248
225
  run "mkdir #{dir}"
249
- run "touch #{dir}/.gitkeep"
226
+ run "touch #{dir}/.keep"
250
227
  end
251
228
  end
252
229
 
@@ -298,7 +275,7 @@ module RailsloveSuspenders
298
275
 
299
276
  def setup_default_rake_task
300
277
  append_file 'Rakefile' do
301
- "task(:default).clear\ntask :default => [:spec]"
278
+ "task(:default).clear\ntask :default => [:spec]\n"
302
279
  end
303
280
  end
304
281
 
@@ -315,8 +292,5 @@ module RailsloveSuspenders
315
292
  IO.read find_in_source_paths('factories_spec_rake_task.rb')
316
293
  end
317
294
 
318
- def simplecov_init
319
- IO.read find_in_source_paths('simplecov_init.rb')
320
- end
321
295
  end
322
296
  end
@@ -30,7 +30,6 @@ module RailsloveSuspenders
30
30
  invoke :setup_staging_environment
31
31
  invoke :create_suspenders_views
32
32
  invoke :create_common_javascripts
33
- # invoke :add_jquery_ui
34
33
  invoke :configure_app
35
34
  invoke :setup_stylesheets
36
35
  invoke :copy_miscellaneous_files
@@ -90,7 +89,6 @@ module RailsloveSuspenders
90
89
  def setup_staging_environment
91
90
  say 'Setting up the staging environment'
92
91
  build :setup_staging_environment
93
- build :initialize_on_precompile
94
92
  end
95
93
 
96
94
  def create_suspenders_views
@@ -108,11 +106,6 @@ module RailsloveSuspenders
108
106
  build :create_common_javascripts
109
107
  end
110
108
 
111
- def add_jquery_ui
112
- say 'Add jQuery ui to the standard application.js'
113
- build :add_jquery_ui
114
- end
115
-
116
109
  def configure_app
117
110
  say 'Configuring app'
118
111
  build :configure_action_mailer
@@ -1,4 +1,4 @@
1
1
  module RailsloveSuspenders
2
- VERSION = '0.1.1'
2
+ VERSION = '0.1.2'
3
3
  # suspenders 1.3.0
4
4
  end
@@ -6,10 +6,9 @@ require 'date'
6
6
  Gem::Specification.new do |s|
7
7
  s.required_ruby_version = '>= 1.9.2'
8
8
  s.add_dependency 'bundler', '~> 1.3'
9
- s.add_dependency 'hub', '~> 1.10'
10
9
  s.add_dependency 'rails', '4.0.0'
11
- # s.add_development_dependency 'aruba', '~> 0.5'
12
- # s.add_development_dependency 'cucumber', '~> 1.2'
10
+ s.add_development_dependency 'aruba', '~> 0.5'
11
+ s.add_development_dependency 'cucumber', '~> 1.2'
13
12
  s.authors = ['stephanpavlovic']
14
13
  s.date = Date.today.strftime('%Y-%m-%d')
15
14
 
@@ -1,20 +1,16 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
3
  gem 'airbrake'
4
- gem 'compass'
4
+ gem 'coffee-rails'
5
+ gem 'compass-rails'
5
6
  gem 'jquery-rails'
6
7
  gem 'pg'
7
8
  gem 'rails', '>= 4.0.0'
8
9
  gem 'quiet_assets'
10
+ gem 'sass-rails'
9
11
  gem 'newrelic_rpm'
10
12
  gem 'haml-rails'
11
-
12
- group :assets do
13
- gem 'coffee-rails'
14
- gem 'compass-rails'
15
- gem 'sass-rails'
16
- gem 'uglifier'
17
- end
13
+ gem 'uglifier'
18
14
 
19
15
  group :development do
20
16
  gem 'better_errors'
@@ -24,11 +20,11 @@ end
24
20
 
25
21
  group :development, :test do
26
22
  gem 'factory_girl_rails'
27
- gem 'rspec-rails'
23
+ gem 'rspec-rails', '>= 2.14'
28
24
  end
29
25
 
30
26
  group :test do
31
- gem 'capybara-webkit', '>= 0.14.1'
27
+ gem 'capybara-webkit', '>= 1.0.0'
32
28
  gem 'database_cleaner'
33
29
  gem 'launchy'
34
30
  gem 'shoulda-matchers'
@@ -1,3 +1,3 @@
1
1
  # Protect against injection attacks
2
2
  # http://www.kb.cert.org/vuls/id/380039
3
- ActionDispatch::ParamsParser::DEFAULT_PARSERS.delete(Mime::XML)
3
+ ActionDispatch::ParamsParser::DEFAULT_PARSERS.delete(Mime::XML)
@@ -10,5 +10,5 @@
10
10
  @import base/sprites
11
11
  @import base/typography
12
12
 
13
- @import layout/*
14
- @import modules/*
13
+ // @import layout/*
14
+ // @import modules/*
@@ -1,10 +1,16 @@
1
1
  !.keep
2
2
  *.DS_Store
3
+ *.swo
3
4
  *.swp
4
- .env
5
+ .bundle
6
+ .sass-cache/
5
7
  bin/stubs
6
8
  coverage/*
9
+ db/*.sqlite3
10
+ db/schema.rb
11
+ log/*
7
12
  public/system
8
13
  rerun.txt
9
14
  tags
10
- vendor/bundler_gems
15
+ tmp/*
16
+ tmp/**/*
@@ -7,6 +7,6 @@
7
7
  = stylesheet_link_tag :application, :media => 'all'
8
8
  = csrf_meta_tags
9
9
  %body{class: controller_name, id: "#{controller_name}_#{action_name}"}
10
- = render 'flashes'
10
+ = render 'layouts/flashes'
11
11
  = yield
12
- = render 'javascript'
12
+ = render 'layouts/javascript'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: railslove-suspenders
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -28,37 +28,53 @@ dependencies:
28
28
  - !ruby/object:Gem::Version
29
29
  version: '1.3'
30
30
  - !ruby/object:Gem::Dependency
31
- name: hub
31
+ name: rails
32
32
  requirement: !ruby/object:Gem::Requirement
33
33
  none: false
34
34
  requirements:
35
- - - ~>
35
+ - - '='
36
36
  - !ruby/object:Gem::Version
37
- version: '1.10'
37
+ version: 4.0.0
38
38
  type: :runtime
39
39
  prerelease: false
40
40
  version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - '='
44
+ - !ruby/object:Gem::Version
45
+ version: 4.0.0
46
+ - !ruby/object:Gem::Dependency
47
+ name: aruba
48
+ requirement: !ruby/object:Gem::Requirement
41
49
  none: false
42
50
  requirements:
43
51
  - - ~>
44
52
  - !ruby/object:Gem::Version
45
- version: '1.10'
53
+ version: '0.5'
54
+ type: :development
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ~>
60
+ - !ruby/object:Gem::Version
61
+ version: '0.5'
46
62
  - !ruby/object:Gem::Dependency
47
- name: rails
63
+ name: cucumber
48
64
  requirement: !ruby/object:Gem::Requirement
49
65
  none: false
50
66
  requirements:
51
- - - '='
67
+ - - ~>
52
68
  - !ruby/object:Gem::Version
53
- version: 4.0.0
54
- type: :runtime
69
+ version: '1.2'
70
+ type: :development
55
71
  prerelease: false
56
72
  version_requirements: !ruby/object:Gem::Requirement
57
73
  none: false
58
74
  requirements:
59
- - - '='
75
+ - - ~>
60
76
  - !ruby/object:Gem::Version
61
- version: 4.0.0
77
+ version: '1.2'
62
78
  description: ! 'Suspenders is a base Rails project that you can upgrade. It is used
63
79
  by
64
80