Browse Source

Make extract_pot also work on Windows

pull/846/merge
Safihre 8 years ago
parent
commit
f1b139d55d
  1. 7
      tools/extract_pot.py

7
tools/extract_pot.py

@ -130,15 +130,16 @@ if not os.path.exists(PO_DIR):
path, exe = os.path.split(sys.executable) path, exe = os.path.split(sys.executable)
if os.name == 'nt': if os.name == 'nt':
TOOL = os.path.join(path, r'Tools\i18n\pygettext.py') TOOL = os.path.join(path, r'Tools\i18n\pygettext.py')
TOOL = 'python ' + TOOL
else: else:
TOOL = os.path.join(path, 'pygettext.py') TOOL = os.path.join(path, 'pygettext.py')
if not os.path.exists(TOOL): if not os.path.exists(TOOL):
TOOL = 'pygettext' TOOL = 'pygettext'
cmd = '%s %s %s' % (TOOL, PARMS, FILES) cmd = '%s %s %s' % (TOOL, PARMS, FILES)
print 'Create POT file' print 'Create POT file'
# print cmd #print cmd
os.system(cmd) os.system(cmd)
print 'Post-process the POT file' print 'Post-process the POT file'

Loading…
Cancel
Save