0

我是 Rails 新手,为了完成任务,我尝试了命令

rails generate simple_form:install --bootstrap

正如建议的那样,但最终会出现错误,这些错误是-

Running via Spring preloader in process 1006
Expected string default value for '--test-framework'; got false (boolean)
Expected string default value for '--jbuilder'; got true (boolean)
Expected string default value for '--test-framework'; got false (boolean)
Expected string default value for '--helper'; got true (boolean)
Expected string default value for '--assets'; got true (boolean)
Expected string default value for '--test-framework'; got false (boolean)
Expected string default value for '--test-framework'; got false (boolean)
Expected string default value for '--test-framework'; got false (boolean)
Expected string default value for '--test-framework'; got false (boolean)
Expected string default value for '--test-framework'; got false (boolean)
Could not find generator 'simple_form:install'.
Maybe you meant 'integration_test', 'scaffold' or 'active_record:model'
Run `rails generate --help` for more options.

谁能帮我弄清楚出了什么问题以及我必须做什么?

我已经使用命令安装了 gem simple_form(3.4.0) 和 bootstrap-sass(3.3.7)

 gem install simple_form
 gem install bootstrap-sass
 bundle install
4

2 回答 2

0

You have to put simple_form and bootstrap-sass into your Gemfile before runnign bundle install. If the problem persists, please do post your Gemfile for clarification.

于 2017-01-11T06:44:02.917 回答
0

将这两行放在 gemfile 中,如下所示...

gem 'simple_form'
gem 'bootstrap-sass'

然后开火命令bundle install

于 2017-01-11T06:52:28.210 回答