From caffbfa94b84569fb64ed6ecb68f9ca960deca2a Mon Sep 17 00:00:00 2001 From: Yaohan Chen Date: Sat, 7 Jun 2008 14:30:33 -0400 Subject: recommit 33c336af346dc08b4f4f4951dd6eae7150cef481 po file per plugin each plugin uses its own po file, no change required for plugin source, Rakefile, plugin loader and gettext loader are modified to adjust to the change --- Rakefile | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'Rakefile') diff --git a/Rakefile b/Rakefile index f0a42717..b44ca95f 100644 --- a/Rakefile +++ b/Rakefile @@ -38,7 +38,15 @@ end desc "Update pot/po files." task :updatepo do require 'gettext/utils' - GetText.update_pofiles("rbot", Dir.glob("{lib,bin,data}/**/*.{rb,rhtml}"), "rbot") + plugin_files = Dir.glob('data/rbot/plugins/**/*.rb') + # all except plugin files use the rbot textdomain + GetText.update_pofiles("rbot", + Dir.glob("{lib,bin,data}/**/*.{rb,rhtml}") - plugin_files, "rbot") + # each plugin uses its own textdomain + plugin_files.each do |f| + basename = File.basename(f, '.rb') + GetText.update_pofiles("rbot-#{basename}", f, 'rbot') + end end desc "Create mo-files" -- cgit v1.2.3