I wanted to use the latest ember source by adding this to my Gemfile:
Adding this to a gemfile:
gem 'ember-rails', git: "git://github.com/emberjs/ember-rails.git"
gem 'ember-source', git: "git://github.com/emberjs/ember.js.git"
gem 'ember-data-source', git: "git://github.com/emberjs/data.git"
Results in this error:
/Users/alex/.rbenv/versions/1.9.3-p392/lib/ruby/1.9.1/fileutils.rb:1515:in `stat': No such file or directory - /Users/alex/.rbenv/versions/1.9.3-p392/lib/ruby/gems/1.9.1/bundler/gems/data-9d6686cf1366/dist/ember-data.js (Errno::ENOENT)
Essentially there's no way to use ember-rails with the HEAD version of ember, which would be great as who knows when the next release of ember-source will be?
As an interim solution you may be able to use one of the interim 1.0.0.rc1.x pre-release gems: https://rubygems.org/gems/ember-source
@tchak do you have a chance to take a look at this?
Unfortunately 1.0.0.rc1.4 was released on March 18, 2013, but I need this commit which was March 23rd in order to extend LinkView for ember-query
I think the problem is not with ember-rails, but the way the ember.js and ember-data gems are - the dist directory is not commited. If I do bundle open ember-source and then run rake dist, it works but this is not suitable for deployment. I'm sure there's a way of defining a rake task in the gemspec (I can't find it right now, unless it's something to do with GemPackageTask) - so I think the solution is updating the gemspec in ember-data and ember.js so that gem build actually builds a viable gem - should I open issues on those projects instead and close this one?
(Edit) This stackoverflow answer is not promising, and I'm not sure if this is the right solution anyway. Perhaps the answer is that "adding ember.js and ember-data git repos to your Gemfile is not supported and the gemspec is only in those repos as a convenience to the ember developers"?
@machty thoughts? Can we treat the build step like a compile step for native ruby extensions?
@alexspeller this is why I was from the start to have a rake task that downloads an ember build from the cdn and drop it in project's vendor directory.
I would be in favor of removing the git clone task and replace it with the download task.
The problem is that dist is gitignored in the ember.js repo. Presently if you want to use ember-source for grabbing the latest ember data, you either have to wait for us to push to ember-source, or you can do something like
gem 'ember-source', path: '../ember.js'
Where .../ember.js is a clone of the ember.js repo with the /dist directory freshly rebuilt via rake dist
The rake task sounds like a good idea to me - I used that before and it worked fine, and for better or worse Ember is still in flux and keeping up to date with HEAD is still necessary for some.
What's the progress on this? I'd love to see this issue resolved.
https://github.com/emberjs/ember-rails#getting-started has a posted solution...
Once we are out of rc-town we should be back to something that isn't such a pain.