Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
242 views
in Technique[技术] by (71.8m points)

capistrano - rails active admin deployment : couldn't find file 'jquery-ui'

when trying to deploy with capistrano, when capistrano use command bundle exec rake

    RAILS_ENV=production 
    RAILS_GROUPS=assets 
    assets:precompile

I have this error

couldn't find file 'jquery-ui'
  (in /home/umbrosus/.rvm/gems/ruby-1.9.3-p392@gancxadebebi/gems/activeadmin-0.5.1/app/assets/javascripts/active_admin/base.js:2)

Before it was working well, but I tried to update to 0.6 and then I started to have this error. I came back to 0.5.1 and the error is still there. Do I do something bad ?

thanks

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

The "jquery-rails" gem recently removed jQuery UI.

https://github.com/rails/jquery-rails/commit/2fdcdb2633cbc6426d412c050200fc31d14b9a3b

They recommend using the jquery-ui-rails gem.

There is an active pull request (as of this writing) to add that gem as a dependency. However, the developers of ActiveAdmin have stated that they are "locking it down until we officially drop support for Rails 3.0". The version they are locked to is jquery-rails < 3.0.0.

In the meantime, just modify your Gemfile:

gem "jquery-ui-rails" Not recommended, see @Kevin's comment below

Or you can downgrade your version of jquery-rails:

gem "jquery-rails", "< 3.0.0"

Or you can pull from their Github master branch. They have applied a temporary fix.

gem "activeadmin", github: "gregbell/active_admin"

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...