stationed 0.0.1 → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE +1 -1
  3. data/README.md +6 -3
  4. data/lib/stationed/generators/app_generator.rb +0 -1
  5. data/lib/stationed/generators/plugins/capybara.rb +8 -0
  6. data/lib/stationed/generators/plugins/capybara_webkit.rb +8 -0
  7. data/lib/stationed/generators/plugins/database_cleaner.rb +8 -0
  8. data/lib/stationed/generators/plugins/devise.rb +11 -1
  9. data/lib/stationed/generators/plugins/draper.rb +8 -0
  10. data/lib/stationed/generators/plugins/factory_girl.rb +8 -0
  11. data/lib/stationed/generators/plugins/flashes.rb +8 -0
  12. data/lib/stationed/generators/plugins/foreman.rb +9 -1
  13. data/lib/stationed/generators/plugins/generators.rb +8 -0
  14. data/lib/stationed/generators/plugins/guard.rb +9 -0
  15. data/lib/stationed/generators/plugins/haml.rb +8 -0
  16. data/lib/stationed/generators/plugins/i18n_spec.rb +8 -0
  17. data/lib/stationed/generators/plugins/kaminari.rb +9 -0
  18. data/lib/stationed/generators/plugins/layout.rb +8 -0
  19. data/lib/stationed/generators/plugins/pry.rb +8 -0
  20. data/lib/stationed/generators/plugins/pundit.rb +9 -0
  21. data/lib/stationed/generators/plugins/rack_deflater.rb +8 -0
  22. data/lib/stationed/generators/plugins/responders.rb +8 -0
  23. data/lib/stationed/generators/plugins/rspec.rb +9 -0
  24. data/lib/stationed/generators/plugins/rubocop.rb +8 -0
  25. data/lib/stationed/generators/plugins/simple_form.rb +9 -0
  26. data/lib/stationed/generators/plugins/simple_form_inputs.rb +8 -0
  27. data/lib/stationed/generators/plugins/spring.rb +8 -0
  28. data/lib/stationed/generators/plugins/stationed.rb +8 -0
  29. data/lib/stationed/generators/plugins/strong_parameters.rb +8 -0
  30. data/lib/stationed/generators/plugins/styles.rb +10 -0
  31. data/lib/stationed/generators/plugins/turbolinks.rb +8 -0
  32. data/lib/stationed/generators/plugins/webmock.rb +8 -0
  33. data/lib/stationed/generators/plugins/wiki.rb +8 -0
  34. data/lib/stationed/generators/plugins/yard.rb +8 -0
  35. data/lib/stationed/generators/templates/application.html.haml +1 -0
  36. data/lib/stationed/version.rb +1 -1
  37. data/spec/dummy/log/test.log +56 -0
  38. metadata +2 -3
  39. data/lib/stationed/generators/plugins/normalize.rb +0 -12
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 38bb78f102e4d35a45d2226d922a0f2c183aa54b
4
- data.tar.gz: 312a9980d2168f891695ff3897863a7e69b49a44
3
+ metadata.gz: ddd733df0111d69ab25025b8cd2cd21d46b5df23
4
+ data.tar.gz: b1574b28a98ef141d8b7b1354f07848edc6f3c87
5
5
  SHA512:
6
- metadata.gz: ee86970abab0e607e449ed93c2104579e1bd903769f53245e0b41c38b856c00b1deec5c663e99cd4fb38e715f04f35071a7e1f281b95b37a0bb8eb9d89f16d4e
7
- data.tar.gz: d909f871bcbbffb800249f7924ad69ea19921b1ce279c99d931b73b03f162100d51fc4a646b1f2d8e57d65da98bd010e2f0207aa54896f77302a3b61607502cc
6
+ metadata.gz: b658a1b9f224f88cd45eefd99a32e3a1b942d22c5e958b995f08d3840dd1dff4c228172fa2d290251b64b787e50b04de8669258122c447f2b9e959ad13bfa486
7
+ data.tar.gz: 40ab1e4c1ca98273577df0f1e0235aa1ccec4df7dac8e1e344d3a64625efd762252fb52d72a81073b2660c6001af17373f5521e38f3697878afeef5e84ec476b
data/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright 2014 YOURNAME
1
+ Copyright 2014 Arjan van der Gaag
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -55,8 +55,11 @@ This will generate a default Rails application with the following additions:
55
55
  ...and some other minor configurations and goodies.
56
56
 
57
57
  All these additions are stand-alone "plugins" for the base application
58
- generator, so it is easy to adapt them or add others. Have a look at
59
- `lib/stationed/generators/plugins` to see all plugins.
58
+ generator, so it is easy to adapt them or add others. Plugins have their own CLI
59
+ options, so you can easily enable or disable them. To see the available options,
60
+ run:
61
+
62
+ % stationed -h
60
63
 
61
64
  ## Helpers
62
65
 
@@ -131,6 +134,6 @@ See the [HISTORY](https://github.com/avdgaag/stationed/blob/master/HISTORY.md) f
131
134
  Created by: Arjan van der Gaag
132
135
  URL: [http://arjanvandergaag.nl](http://arjanvandergaag.nl)
133
136
  Project homepage:
134
- [http://avdgaag.github.com/rpub](http://avdgaag.github.com/stationed)
137
+ [http://avdgaag.github.com/stationed](http://avdgaag.github.com/stationed)
135
138
  Date: april 2014
136
139
  License: [MIT-license](https://github.com/avdgaag/stationed/LICENSE) (same as Ruby)
@@ -35,7 +35,6 @@ module Stationed
35
35
  prepend Plugins::Flashes
36
36
  prepend Plugins::Webmock
37
37
  prepend Plugins::Layout
38
- prepend Plugins::Normalize
39
38
  prepend Plugins::I18nSpec
40
39
  prepend Plugins::SimpleFormInputs
41
40
  prepend Plugins::Spring
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Capybara
5
+ def self.prepended(base)
6
+ base.class_option :capybara,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include Capybara'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:capybara]
6
14
  gem 'capybara', group: :test
7
15
  super
8
16
  end
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module CapybaraWebkit
5
+ def self.prepended(base)
6
+ base.class_option :capybara_webkit,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include CapybaraWebkit for headless browser testing'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:capybara] && options[:capybara_webkit]
6
14
  gem 'capybara-webkit', group: :test
7
15
  copy_file 'capybara_webkit.rb', 'spec/support/capybara_webkit.rb'
8
16
  super
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module DatabaseCleaner
5
+ def self.prepended(base)
6
+ base.class_option :database_cleaner,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Replace transactional fixtures with DatabaseCleaner'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:database_cleaner]
6
14
  gem 'database_cleaner', group: :test
7
15
  copy_file 'database_cleaner.rb', 'spec/support/database_cleaner.rb'
8
16
  super
@@ -2,9 +2,17 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Devise
5
+ def self.prepended(base)
6
+ base.class_option :devise,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Set up authentication with Devise'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:devise]
6
14
  gem 'devise'
7
- copy_file 'devise.rb', 'spec/support/devise.rb'
15
+ copy_file 'devise.rb', 'spec/support/devise.rb' if options[:rspec]
8
16
  route "devise_scope :user do\n root to: 'devise/sessions#new'\n end\n"
9
17
  environment nil, env: :test do
10
18
  "config.action_mailer.default_url_options = { host: 'example.com' }"
@@ -17,8 +25,10 @@ module Stationed
17
25
 
18
26
  def run_bundle
19
27
  super
28
+ return unless options[:devise]
20
29
  generate 'devise:install'
21
30
  generate 'devise user'
31
+ return unless options[:pundit]
22
32
  application do
23
33
  <<-RUBY
24
34
  # Let Pundit authorization or custom responders not influence the workings
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Draper
5
+ def self.prepended(base)
6
+ base.class_option :draper,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include and configure draper for view decorators'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:draper]
6
14
  gem 'draper'
7
15
  copy_file 'application_decorator.rb', 'app/decorators/application_decorator.rb'
8
16
  copy_file 'paginating_decorator.rb', 'app/decorators/paginating_decorator.rb'
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module FactoryGirl
5
+ def self.prepended(base)
6
+ base.class_option :factory_girl,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include FactoryGirl and default tests for valid factories'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:factory_girl]
6
14
  gem 'factory_girl_rails', group: [:development, :test]
7
15
  copy_file 'factory_girl.rb', 'spec/support/factory_girl.rb'
8
16
  copy_file 'factories_spec.rb', 'spec/models/factories_spec.rb'
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Flashes
5
+ def self.prepended(base)
6
+ base.class_option :flashes,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include generic flashes partial'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:flashes] && options[:layout]
6
14
  copy_file 'flashes.html.haml', 'app/views/application/_flashes.html.haml'
7
15
  super
8
16
  end
@@ -2,9 +2,17 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Foreman
5
+ def self.prepended(base)
6
+ base.class_option :foreman,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Configure Foreman with a Procfile and .env file'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:foreman]
6
14
  gem 'foreman'
7
- gem 'yard', require: false, group: :doc
15
+ gem 'dotenv-rails'
8
16
  copy_file 'Procfile', 'Procfile'
9
17
  template 'env.erb', '.env'
10
18
  super
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Generators
5
+ def self.prepended(base)
6
+ base.class_option :generators,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Set up default generators to disable helpers, assets, etc'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:generators]
6
14
  copy_file 'generators.rb', 'config/initializers/generators.rb'
7
15
  super
8
16
  end
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Guard
5
+ def self.prepended(base)
6
+ base.class_option :guard,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include Guard for Rspec and Livereload'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:guard]
6
14
  gem_group :development do
7
15
  gem 'guard'
8
16
  gem 'guard-rspec'
@@ -14,6 +22,7 @@ module Stationed
14
22
 
15
23
  def run_bundle
16
24
  super
25
+ return unless options[:guard]
17
26
  run 'bundle exec guard init rspec'
18
27
  run 'bundle exec guard init livereload'
19
28
  gsub_file 'Guardfile',
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Haml
5
+ def self.prepended(base)
6
+ base.class_option :haml,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include Haml as template engine'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:haml]
6
14
  gem 'haml-rails'
7
15
  super
8
16
  end
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module I18nSpec
5
+ def self.prepended(base)
6
+ base.class_option :i18n_spec,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Set up tests for locale files'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:i18n_spec]
6
14
  gem 'i18n-spec', group: :test
7
15
  copy_file 'i18n_spec.rb', 'spec/locales/i18n_spec.rb'
8
16
  super
@@ -2,13 +2,22 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Kaminari
5
+ def self.prepended(base)
6
+ base.class_option :kaminari,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include Kaminari with config and views for pagination'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:kaminari]
6
14
  gem 'kaminari'
7
15
  super
8
16
  end
9
17
 
10
18
  def run_bundle
11
19
  super
20
+ return unless options[:kaminari]
12
21
  generate 'kaminari:config'
13
22
  generate 'kaminari:views default'
14
23
  end
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Layout
5
+ def self.prepended(base)
6
+ base.class_option :layout,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Add a generic Haml application layout file'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:layout]
6
14
  remove_file 'app/views/layouts/application.html.haml'
7
15
  copy_file 'application.html.haml', 'app/views/layouts/application.html.haml'
8
16
  super
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Pry
5
+ def self.prepended(base)
6
+ base.class_option :pry,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include Pry debugging gems'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:pry]
6
14
  gem_group :development, :test do
7
15
  gem 'pry-rails'
8
16
  gem 'pry-byebug'
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Pundit
5
+ def self.prepended(base)
6
+ base.class_option :pundit,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include and configure Pundit for authorization'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:pundit]
6
14
  gem 'pundit'
7
15
  copy_file 'pundit.rb', 'spec/support/pundit.rb'
8
16
  copy_file 'authorization.rb', 'app/controllers/concerns/authorization.rb'
@@ -12,6 +20,7 @@ module Stationed
12
20
 
13
21
  def run_bundle
14
22
  super
23
+ return unless options[:pundit]
15
24
  generate 'pundit:install'
16
25
  end
17
26
  end
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module RackDeflater
5
+ def self.prepended(base)
6
+ base.class_option :rack_deflator,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include rack-deflator in production mode'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:rack_deflator]
6
14
  environment nil, env: :production do
7
15
  <<-RUBY
8
16
  # Enable deflate / gzip compression of controller-generated responses
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Responders
5
+ def self.prepended(base)
6
+ base.class_option :responders,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Add and configure Responders gem for DRY controllers'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:responders]
6
14
  gem 'responders'
7
15
  copy_file 'application_responder.rb', 'lib/application_responder.rb'
8
16
 
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Rspec
5
+ def self.prepended(base)
6
+ base.class_option :rspec,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Generate configuration for Rspec with Simplecov'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:rspec]
6
14
  gem 'simplecov', group: :test
7
15
  gem 'rspec-rails', group: [:development, :test]
8
16
  copy_file 'simplecov', '.simplecov'
@@ -11,6 +19,7 @@ module Stationed
11
19
 
12
20
  def run_bundle
13
21
  super
22
+ return unless options[:rspec]
14
23
  generate 'rspec:install'
15
24
  remove_file 'spec/spec_helper.rb'
16
25
  copy_file 'spec_helper.rb', 'spec/spec_helper.rb'
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Rubocop
5
+ def self.prepended(base)
6
+ base.class_option :rubocop,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include configuration and tasks to run Rubocop.'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:rubocop]
6
14
  gem 'rubocop', group: :development
7
15
  copy_file 'rubocop.rake', 'lib/tasks/rubocop.rake'
8
16
  copy_file 'rubocop.yml', '.rubocop.yml'
@@ -2,13 +2,22 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module SimpleForm
5
+ def self.prepended(base)
6
+ base.class_option :simple_form,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include and configure simple_form as FormBuilder'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:simple_form]
6
14
  gem 'simple_form'
7
15
  super
8
16
  end
9
17
 
10
18
  def run_bundle
11
19
  super
20
+ return unless options[:simple_form]
12
21
  generate 'simple_form:install'
13
22
  remove_file 'config/initializers/simple_form.rb'
14
23
  copy_file 'simple_form.rb', 'config/initializers/simple_form.rb'
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module SimpleFormInputs
5
+ def self.prepended(base)
6
+ base.class_option :simple_form_inputs,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Install custom simple_form inputs'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:simple_form] && options[:simple_form_inputs]
6
14
  copy_file 'static_input.rb', 'app/inputs/static_input.rb'
7
15
  copy_file 'select2_input.rb', 'app/inputs/select2_input.rb'
8
16
  super
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Spring
5
+ def self.prepended(base)
6
+ base.class_option :spring,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Add Rspec spring commands and configuration'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:spring]
6
14
  gem 'spring-commands-rspec', group: :development
7
15
  copy_file 'spring.rb', 'config/spring.rb'
8
16
  super
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Stationed
5
+ def self.prepended(base)
6
+ base.class_option :stationed,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include stationed itself as an engine'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:stationed]
6
14
  gem 'stationed', path: '~/code/stationed'
7
15
  super
8
16
  end
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module StrongParameters
5
+ def self.prepended(base)
6
+ base.class_option :strong_parameters,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Be strict about strong parameters in development'
10
+ end
11
+
5
12
  def finish_template
13
+ returns uper unless options[:strong_parameters]
6
14
  environment nil, env: :development do
7
15
  <<-RUBY
8
16
  # Raise an ActionController::UnpermittedParameters exception when
@@ -2,18 +2,28 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Styles
5
+ def self.prepended(base)
6
+ base.class_option :styles,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include Bourbon, Neat, Bitters and Normalize.css'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:styles]
6
14
  gem 'bourbon'
7
15
  gem 'neat'
8
16
  gem 'bitters'
9
17
  remove_file 'app/assets/stylesheets/application.css'
10
18
  copy_file 'application.scss', 'app/assets/stylesheets/application.scss'
11
19
  copy_file 'layout.scss', 'app/assets/stylesheets/_layout.scss'
20
+ copy_file 'normalize.css', 'vendor/assets/stylesheets/normalize.css'
12
21
  super
13
22
  end
14
23
 
15
24
  def run_bundle
16
25
  super
26
+ return unless options[:styles]
17
27
  run 'bitters install'
18
28
  FileUtils.mv 'bitters', 'app/assets/stylesheets/bitters'
19
29
  gsub_file 'app/assets/stylesheets/bitters/_bitters.scss', %r{// @import}, '@import'
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Turbolinks
5
+ def self.prepended(base)
6
+ base.class_option :turbolinks,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Remove turbolinks from the generated project'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:turbolinks]
6
14
  gsub_file 'Gemfile', /^gem 'turbolinks'.*\n/, ''
7
15
  gsub_file 'app/assets/javascripts/application.js', %r{//= require turbolinks\n}, ''
8
16
  super
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Webmock
5
+ def self.prepended(base)
6
+ base.class_option :webmock,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Install webmock to prevent external HTTP requests in tests'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:webmock]
6
14
  gem 'webmock', group: :test
7
15
  copy_file 'webmock.rb', 'spec/support/webmock.rb'
8
16
  super
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Wiki
5
+ def self.prepended(base)
6
+ base.class_option :wiki,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include a Gollum-based stub Wiki in ./doc/wiki'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:wiki]
6
14
  gem 'gollum', require: 'gollum/app', group: [:development]
7
15
  route "mount Precious::App => '/wiki' if defined?(Precious)"
8
16
  copy_file 'Home.md', 'doc/wiki/Home.md'
@@ -2,7 +2,15 @@ module Stationed
2
2
  module Generators
3
3
  module Plugins
4
4
  module Yard
5
+ def self.prepended(base)
6
+ base.class_option :yard,
7
+ type: :boolean,
8
+ default: true,
9
+ desc: 'Include and configure Yard for API documentation'
10
+ end
11
+
5
12
  def finish_template
13
+ return super unless options[:yard]
6
14
  gem 'yard', require: false, group: :doc
7
15
  gem 'kramdown', require: false, group: :doc
8
16
  copy_file 'yardopts', '.yardopts'
@@ -7,5 +7,6 @@
7
7
  = stylesheet_link_tag 'application'
8
8
  = csrf_meta_tags
9
9
  %body
10
+ = render 'flashes'
10
11
  = yield
11
12
  = javascript_include_tag 'application'
@@ -1,3 +1,3 @@
1
1
  module Stationed
2
- VERSION = "0.0.1"
2
+ VERSION = '0.1.0'
3
3
  end
@@ -1416,3 +1416,59 @@
1416
1416
   (0.0ms) rollback transaction
1417
1417
   (0.0ms) begin transaction
1418
1418
   (0.1ms) rollback transaction
1419
+  (0.4ms) begin transaction
1420
+  (0.1ms) rollback transaction
1421
+  (0.1ms) begin transaction
1422
+  (0.1ms) rollback transaction
1423
+  (0.0ms) begin transaction
1424
+  (0.0ms) rollback transaction
1425
+  (0.0ms) begin transaction
1426
+  (0.0ms) rollback transaction
1427
+  (0.0ms) begin transaction
1428
+  (0.1ms) rollback transaction
1429
+  (0.0ms) begin transaction
1430
+  (0.0ms) rollback transaction
1431
+  (0.0ms) begin transaction
1432
+  (0.0ms) rollback transaction
1433
+  (0.0ms) begin transaction
1434
+  (0.0ms) rollback transaction
1435
+  (0.0ms) begin transaction
1436
+  (0.0ms) rollback transaction
1437
+  (0.0ms) begin transaction
1438
+  (0.0ms) rollback transaction
1439
+  (0.1ms) begin transaction
1440
+  (0.0ms) rollback transaction
1441
+  (0.0ms) begin transaction
1442
+  (0.0ms) rollback transaction
1443
+  (0.1ms) begin transaction
1444
+  (0.0ms) rollback transaction
1445
+  (0.0ms) begin transaction
1446
+  (0.1ms) rollback transaction
1447
+  (0.2ms) begin transaction
1448
+  (0.1ms) rollback transaction
1449
+  (0.0ms) begin transaction
1450
+  (0.0ms) rollback transaction
1451
+  (0.0ms) begin transaction
1452
+  (0.0ms) rollback transaction
1453
+  (0.0ms) begin transaction
1454
+  (0.1ms) rollback transaction
1455
+  (0.0ms) begin transaction
1456
+  (0.0ms) rollback transaction
1457
+  (0.0ms) begin transaction
1458
+  (0.0ms) rollback transaction
1459
+  (0.0ms) begin transaction
1460
+  (0.0ms) rollback transaction
1461
+  (0.0ms) begin transaction
1462
+  (0.0ms) rollback transaction
1463
+  (0.0ms) begin transaction
1464
+  (0.0ms) rollback transaction
1465
+  (0.1ms) begin transaction
1466
+  (0.0ms) rollback transaction
1467
+  (0.0ms) begin transaction
1468
+  (0.0ms) rollback transaction
1469
+  (0.0ms) begin transaction
1470
+  (0.0ms) rollback transaction
1471
+  (0.0ms) begin transaction
1472
+  (0.0ms) rollback transaction
1473
+  (0.0ms) begin transaction
1474
+  (0.0ms) rollback transaction
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stationed
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Arjan van der Gaag
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-04-11 00:00:00.000000000 Z
11
+ date: 2014-04-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -91,7 +91,6 @@ files:
91
91
  - lib/stationed/generators/plugins/i18n_spec.rb
92
92
  - lib/stationed/generators/plugins/kaminari.rb
93
93
  - lib/stationed/generators/plugins/layout.rb
94
- - lib/stationed/generators/plugins/normalize.rb
95
94
  - lib/stationed/generators/plugins/pry.rb
96
95
  - lib/stationed/generators/plugins/pundit.rb
97
96
  - lib/stationed/generators/plugins/rack_deflater.rb
@@ -1,12 +0,0 @@
1
- module Stationed
2
- module Generators
3
- module Plugins
4
- module Normalize
5
- def finish_template
6
- copy_file 'normalize.css', 'vendor/assets/stylesheets/normalize.css'
7
- super
8
- end
9
- end
10
- end
11
- end
12
- end