我想应用这个线程中提到的action_mailer补丁,但是我以前从来没有应用过补丁,我不知道这些补丁是如何工作的:
https://rails.lighthouseapp.com/projects/8994/tickets/2263
https://rails.lighthouseapp.com/projects/8994/tickets/2263
我的动作邮件宝石在这里:/opt/ruby-enterprise-1.8.6-20090421/lib/ruby/gems/1.8/gems/actionmailer-2.3.2
我假设我需要去那个目录并运行patch命令…这样的东西
cd /opt/ruby-enterprise-1.8.6-20090421/lib/ruby/gems/1.8/gems/ wget https://rails.lighthouseapp.com/attachments/108548/0001-Fix-implicit-multipart-mailer-views-when-RAILS_ROOT.patch patch < 0001-Fix-implicit-multipart-mailer-views-when-RAILS_ROOT.patch
一件事我还不太清楚,补丁文件是指“actionmailer”目录,但我的名字叫做“actionmailer-2.3.2”
解决方法
你通常不想修补宝石源本身.您可能会将宝石冻结到${RAILS_ROOT} / vendor / rails中,然后在本地应用补丁.
从您的${RAILS_ROOT}目录中,将所有的导轨宝石转储到供应商/导轨中
rake rails:freeze:gems
应用补丁
cd vendor/rails/ patch -p1 < 0001-Fix-implicit-multipart-mailer-views-when-RAILS_ROOT.patch