[英]rails g migration error
I don't know what to do. 我不知道该怎么办。 Try to use command 尝试使用命令
$ rails g migration vacancy
but this command give me error: 但是此命令给我错误:
invoke active_record
/home/proger/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych.rb:203:in `parse': (<unknown>): mapping values are not allowed in this context at line 21 column 11 (Psych::SyntaxError)
from /home/proger/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych.rb:203:in `parse_stream'
from /home/proger/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych.rb:151:in `parse'
...
There are many rows in error code 错误代码中有很多行
I don't know how to fix that Thanks 我不知道该如何解决,谢谢
UPDATE UPDATE
development: 发展:
adapter: mysql2 适配器:mysql2
encoding: utf8 编码:utf8
reconnect: false 重新连接:错误
database: jobs 数据库:作业
pool: 5 泳池:5
username: root 用户名:root
password: toor 密码:toor
socket: /var/run/mysqld/mysqld.sock 套接字:/var/run/mysqld/mysqld.sock
update: with sqlite3 there is no problem. 更新:使用sqlite3没问题。 problem in mysql gem mysql gem中的问题
It seems that you have syntax error in yaml file. 似乎您在yaml文件中有语法错误。 Probably it is in config/database.yml
可能是在config/database.yml
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.