Changeset 4451
- Timestamp:
- 04/05/09 20:22:55 (4 years ago)
- Location:
- trunk
- Files:
-
- 2 modified
-
setup.py (modified) (1 diff)
-
utils/i18n/potmanager.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/setup.py
r4386 r4451 211 211 def build_mo_files(self): 212 212 """Build mo files from po and put it into LC_MESSAGES.""" 213 potman.compile(LOCALE_DIR, use_fuzzy=False, distutils_log=self.announce) 213 potman.compile(LOCALE_DIR, create_dirs=True, 214 use_fuzzy=False, distutils_log=self.announce) 214 215 215 216 def build_html_doc(self): -
trunk/utils/i18n/potmanager.py
r4355 r4451 91 91 def compile(self, locale_dir, use_fuzzy=True, verbose=False, 92 92 do_checks=True, statistics=False, appname='umit', 93 mo_dir='LC_MESSAGES', distutils_log=None ):93 mo_dir='LC_MESSAGES', distutils_log=None, create_dirs=False): 94 94 """Traverse locale_dir looking for .po files only inside 95 95 subdirectories and compile them to .mo files.""" … … 107 107 potdir = os.path.dirname(pot) 108 108 mo_path = os.path.join(potdir, mo_dir, "%s.mo" % appname) 109 if not os.path.exists(os.path.dirname(mo_path)) and create_dirs: 110 os.makedirs(os.path.dirname(mo_path)) 109 111 # compile pot 110 112 if verbose:
