gpt4 book ai didi

ruby-on-rails-4 - 轨道 4 上的 gem globalize3

转载 作者:行者123 更新时间:2023-12-04 04:48:03 25 4
gpt4 key购买 nike

有人正在使用带有 rails4 的 globalize3。
你如何配置它?

我尝试在我的 Gemfile 上安装:

gem 'globalize3', github: 'svenfuchs/globalize3', branch: 'rails4'

但我有这些错误:
Bundler could not find compatible versions for gem "railties":
In Gemfile:
globalize3 (>= 0) ruby depends on
railties (~> 3.0) ruby

coffee-rails (~> 4.0.0) ruby depends on
railties (4.0.0)

Bundler could not find compatible versions for gem "rails":
In Gemfile:
globalize3 (>= 0) ruby depends on
rails (~> 3) ruby

rails (4.0.0)

Bundler could not find compatible versions for gem "actionpack":
In Gemfile:
rails (= 4.0.0) ruby depends on
actionpack (= 4.0.0) ruby

simple_form (~> 3.0.0.rc) ruby depends on
actionpack (4.0.0.rc1)

最佳答案

globalize3 gem 已更名 globalize 和主要版本号现在对应于 ActiveRecord 的相应版本(AR3 为 3.x,AR4 为 4.x)。

所以你需要做的就是把它放在你的 Gemfile 中,你不应该有任何冲突:

gem 'globalize', '~> 4.0.0.alpha.2'

另见 github repository了解更多详情。

关于ruby-on-rails-4 - 轨道 4 上的 gem globalize3,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17880923/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com