我需要让我的 jQuery 在 Heroku 上工作。
这是我的控制台:
$ rake assets:precompile
c:/Ruby192/bin/ruby.exe c:/Ruby192/bin/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets
rake aborted!
Access denied for user 'root'@'localhost' (using password: NO)
Tasks: TOP => environment
(See full trace by running task with --trace)
rake aborted!
Command failed with status (1): [c:/Ruby192/bin/ruby.exe c:/Ruby192/bin/rak...]
Tasks: TOP => assets:precompile
(See full trace by running task with --trace)
当我尝试运行时:
$ assets:precompile
sh: assets:precompile: command not found
编辑: 我也将此行添加到 application.rb:
config.assets.initialize_on_precompile = false