File: update_moos.py

package info (click to toggle)
gvb 1.4-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, jessie, jessie-kfreebsd, sid, stretch
  • size: 852 kB
  • ctags: 124
  • sloc: python: 1,256; makefile: 3
file content (17 lines) | stat: -rw-r--r-- 563 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#! /usr/bin/python

#UPDATE:
import os, subprocess

for strings_file in os.listdir('po'):
    if not strings_file.endswith('.po'):
        continue
    lang = strings_file[:-3]
#    subprocess.call(['msgmerge', '-U', 'po/%s' % strings_file, 'po/good-vibrations.pot'])
#    if not os.path.exists('locale/%s/LC_MESSAGES' % lang):
#        os.mkdir('locale/%s' % lang)
#        os.mkdir('locale/%s/LC_MESSAGES' % lang)
    subprocess.call(['msgfmt', 'po/%s' % strings_file, '-o', 'locale/%s/LC_MESSAGES/gvb.mo' % lang])

# (commented because now Launchpad does it)