You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to split my po file(app.po) into 2 files one for the admin section and other for the public view of my app. How can I do that?. I have been checking text_domain things but I am not able to find the way to do it.
The point is, is there any way to do rake gettext:find and get two different po files even if that requires me some markup work?
Thank you very much.
Best.
Miguel
The text was updated successfully, but these errors were encountered:
hmmmm at first Id suggest that a before_filter sets the correct text-domain for each request.
Idea 1
adjust the first gettext:find pattern to Dir.glob("{app,lib,config,#{locale_path}}/**/*.{rb,erb,haml}").reject{|f|f.include?('admin')}
make a second gettext:find command and use the opposite Dir.glob("{app,lib,config,#{locale_path}}/**/*.{rb,erb,haml}").select{|f|f.include?('/admin/')}
Idea 2
run rake gettext:find and then copy the resulting po files to e.g. admin.po
and then remove any translation that has only usages in admin from the original and remove any translation that has no usage in admin from the second one.
idea 3
move all the admin stuff to tmp, run gettext:find and then move them back
if you do any po-parsing get_pomo could be helpful
Hello.
I would like to split my po file(app.po) into 2 files one for the admin section and other for the public view of my app. How can I do that?. I have been checking text_domain things but I am not able to find the way to do it.
The point is, is there any way to do rake gettext:find and get two different po files even if that requires me some markup work?
Thank you very much.
Best.
Miguel
The text was updated successfully, but these errors were encountered: