From 92a953862d47567a13880a4b587dd43a09f507aa Mon Sep 17 00:00:00 2001 From: Tomeu Vizoso Date: Sun, 29 Jul 2007 10:20:45 +0000 Subject: #2564: use the activity service name as the base name for translation files. --- (limited to 'sugar/activity') diff --git a/sugar/activity/bundlebuilder.py b/sugar/activity/bundlebuilder.py index 6712146..781a569 100644 --- a/sugar/activity/bundlebuilder.py +++ b/sugar/activity/bundlebuilder.py @@ -106,6 +106,10 @@ def _delete_backups(arg, dirname, names): if name.endswith('~') or name.endswith('pyc'): os.remove(os.path.join(dirname, name)) +def _get_service_name(): + bundle = Bundle(_get_source_path()) + return bundle.get_service_name() + def cmd_help(): print 'Usage: \n\ setup.py dev - setup for development \n\ @@ -224,7 +228,7 @@ def cmd_genmo(bundle_name, manifest): if not os.path.isdir(mo_path): os.makedirs(mo_path) - mo_file = os.path.join(mo_path, "%s.mo" % bundle_name) + mo_file = os.path.join(mo_path, "%s.mo" % _get_service_name()) args = ["msgfmt", "--output-file=%s" % mo_file, file_name] retcode = subprocess.call(args) if retcode: -- cgit v0.9.1