diff options
author | Kasper Timm Hansen <kaspth@gmail.com> | 2018-12-18 22:11:22 +0100 |
---|---|---|
committer | Kasper Timm Hansen <kaspth@gmail.com> | 2018-12-18 22:11:22 +0100 |
commit | 849f2b6634074d32ab35e4537f9f2852d5052e80 (patch) | |
tree | aac37e6444281c7498d4f284cf955639b3c9a88e /lib/tasks | |
parent | 7cf7ba4db535ea45e70e844cb653909be6143fd5 (diff) | |
download | rails-849f2b6634074d32ab35e4537f9f2852d5052e80.tar.gz rails-849f2b6634074d32ab35e4537f9f2852d5052e80.tar.bz2 rails-849f2b6634074d32ab35e4537f9f2852d5052e80.zip |
Resurrect installer.
Running `./bin/rails generate mailbox application --no-test-framework` generates:
```
class ApplicationMailbox < ApplicationMailbox
def process
end
end
```
which is not correct for the application mailbox. It shouldn't
respond to process but it should contain a routing hint.
Generally generators aren't meant to be used like the previous commit.
The mailbox generator can certainly add in the ApplicationMailbox
if missing, but it shouldn't be called with "application" as an argument.
Also adds back auto inserting an `ingress` config line in
`config/environmnets/production.rb`.
Fixes #13.
[Kasper Timm Hansen, Andrew Babichev]
Diffstat (limited to 'lib/tasks')
-rw-r--r-- | lib/tasks/install.rake | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/tasks/install.rake b/lib/tasks/install.rake index 598e30c2d4..0885e2d6a5 100644 --- a/lib/tasks/install.rake +++ b/lib/tasks/install.rake @@ -5,10 +5,11 @@ namespace :action_mailbox do Rake::Task["install:migrations"].clear_comments desc "Copy over the migration" - task install: %w[ environment run_generator copy_migrations ] + task install: %w[ environment run_installer copy_migrations ] - task :run_generator do - system "#{RbConfig.ruby} ./bin/rails generate mailbox application --no-test-framework" + task :run_installer do + installer_template = File.expand_path("../rails/generators/installer.rb", __dir__) + system "#{RbConfig.ruby} ./bin/rails app:template LOCATION=#{installer_template}" end task :copy_migrations do |