2013-03-28 169 views
2

我有ember-rails更新主:如何將ember-data的ember-data版本升級到版本12?

bundle update ember-rails 
Updating git://github.com/emberjs/ember-rails.git 
Fetching gem metadata from https://rubygems.org/......... 
.... 
Using ember-rails (0.11.1) from git://github.com/emberjs/ember-rails.git (at master) 
.... 
Your bundle is updated! 

我想使用最新版本ember-data(12),但每次更新我的應用程序的存儲版本號12,即:

App.Store = DS.Store.extend({ 
    revision: 12, 
    adapter: App.Adapter.create() 
}); 

我看到了以下錯誤消息:

Uncaught Error: Error: The Ember Data library has had breaking API changes since the last time you updated the library. Please review the list of breaking changes at https://github.com/emberjs/data/blob/master/BREAKING_CHANGES.md, then update your store's `revision` property to 11 

...當我檢查了DS.CURRENT_API_REVISION是11:

console.log(DS.CURRENT_API_REVISION); // 11 

有沒有辦法讓gem進入修訂版本12,還是我必須自己構建ember-data並覆蓋包含的版本?

回答

1

我結束了使用燼護欄產生的餘燼+燼數據然後去除灰燼的,像這樣的更新版本:

rails generate ember:install --head 
rm vendor/assets/ember/development/ember.js vendor/assets/ember/production/ember.js