Rails active_storage:install任务在生成的rails插件/引擎中不可用

时间:2019-09-28 14:34:43

标签: ruby-on-rails ruby rails-engines rails-activestorage

当我尝试以下操作时:

rails plugin new engines/sense --mountable --full
cd engines/sense
rails active_storage:install

我看到以下错误:

rails aborted!
Don't know how to build task 'active_storage:install' (See the list of available tasks with `rails --tasks`)
bin/rails:14:in `<main>'
(See full trace by running task with --trace)

尝试在config/application.rblib/sense/engine.rb中添加以下内容无济于事:

require "rails/all"
require 'active_storage/engine'
Bundler.require(*Rails.groups)

任何有关正在发生的事情的线索将不胜感激。

0 个答案:

没有答案