在ROR中创建数据库时出错

时间:2021-09-30 22:13:59

i m install a bundle after for create database run this commond in terminal

我在创建数据库之后安装了一个bundle,在终端中运行这个commond

rake db:migrate

then this error appears.Please help me what is the problem

然后出现这个错误。请帮我解决问题

dominname@dominname204:~/Desktop/ajaxtree$ rake db:create

NOTE: Gem.cache is deprecated, use Gem::source_index. It will be removed on or after 2011-08-01.

Gem.cache called from /home/domainname/Desktop/ajaxtree/config/boot.rb:25.

NOTE: Gem.source_index is deprecated, use Specification. It will be removed on or after 2011-11-01.

Gem.source_index called from /usr/local/lib/site_ruby/1.8/rubygems.rb:1144.
NOTE: Gem::SourceIndex#search is deprecated with no replacement. It will be removed on or after 2011-11-01.

Gem::SourceIndex#search called from /home/domainname/Desktop/ajaxtree/config/boot.rb:25.

/usr/local/lib/site_ruby/1.8/rubygems/deprecate.rb:62:Warning: Gem::SourceIndex#search support for String patterns is deprecated, use #find_name
Cannot find gem for Rails =1.1.4:

    Install the missing gem with 'gem install -v=1.1.4 rails', or
    change environment.rb to define RAILS_GEM_VERSION with your desired version.

2 个解决方案

#1


1  

Please install the new version of ruby in your system.

请在您的系统中安装新版本的ruby。

#2


1  

Rails 1.1.4 is very very old. But, with the right gemset you might have a go.

Rails 1.1.4非常老。但是,有了合适的宝石,你可能会有所作为。

Try what the error message is telling you:

尝试错误消息告诉您:

gem install -v=1.1.14 rails

If you have all the gem versions in the environment.rb, you stand a chance at being able to install your dependencies.

如果您在environment.rb中拥有所有gem版本,那么您将有机会安装依赖项。

#1


1  

Please install the new version of ruby in your system.

请在您的系统中安装新版本的ruby。

#2


1  

Rails 1.1.4 is very very old. But, with the right gemset you might have a go.

Rails 1.1.4非常老。但是,有了合适的宝石,你可能会有所作为。

Try what the error message is telling you:

尝试错误消息告诉您:

gem install -v=1.1.14 rails

If you have all the gem versions in the environment.rb, you stand a chance at being able to install your dependencies.

如果您在environment.rb中拥有所有gem版本,那么您将有机会安装依赖项。