problem when doing heroku rake db:migrate to rails app
when i do heroku 开发者_开发问答rake db:migrate i get an error cant require jcode, i solved this problem in my localhost:3000 with the solution to overide this code:
require 'jcode'
to this:
if RUBY_VERSION < '1.9'
to the gem contacts source and its worked in the localhost:3000 but when i pushed the app to heroku, heroku reinstalled all the gems and the problem backed. so i need to override again the code in /app/.bundle/gems/.... but when i do cd app, cd .bundle or cd ~/.bundle, i get canot find .bundle dir..
and in the heroku logs its looks like the .bundle dir exsitis
what to do?
This is a ruby version issue obviously!
require 'jcode' if RUBY_VERSION < '1.9' #require 'jcode'
Just add that.
Sorry for not reading. You need to unpack your gem and change it in that directory. I posted that picture which doesn't totally correlate with the exact code you need. But again this is the concept. Let me know if you have issues with this and I can write the exact code.
try switching stacks at heroku
heroku stack:migrate bamboo-ree-1.8.7
精彩评论