mirror of
https://bitbucket.org/smil3y/katie.git
synced 2025-02-24 02:42:55 +00:00
review updatetranslations script
Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
This commit is contained in:
parent
0c28c71e12
commit
fba22ee92c
1 changed files with 7 additions and 10 deletions
|
@ -1,6 +1,6 @@
|
|||
#!/usr/bin/python
|
||||
|
||||
import os, glob, subprocess, shlex
|
||||
import os, glob, subprocess
|
||||
|
||||
components = ('core', 'dbus', 'declarative', 'gui', 'network', 'plugins',
|
||||
'script', 'scripttools', 'sql', 'svg', 'test', 'uitools', 'xml')
|
||||
|
@ -22,13 +22,10 @@ for t in glob.glob('src/tools/*'):
|
|||
tfiles.extend(list_files(t))
|
||||
|
||||
for t in glob.glob('translations/qt*.ts'):
|
||||
if 'tools' in t:
|
||||
files = ' '.join(tfiles)
|
||||
command = ['minsize/bin/lupdate', '-locations', 'relative', '-no-ui-lines', '-no-obsolete']
|
||||
if not 'tools' in t:
|
||||
command.extend(tfiles)
|
||||
else:
|
||||
files = ' '.join(cfiles)
|
||||
command = 'minsize/bin/lupdate -locations relative -no-ui-lines -no-obsolete %s -ts %s' % (files, t)
|
||||
command = shlex.split(command)
|
||||
pipe = subprocess.Popen(command, stderr=subprocess.PIPE)
|
||||
pipe.wait()
|
||||
if pipe.returncode != 0:
|
||||
raise(Exception(pipe.communicate()[1].strip()))
|
||||
command.extend(cfiles)
|
||||
command.extend(['-ts', t])
|
||||
subprocess.check_call(command)
|
||||
|
|
Loading…
Add table
Reference in a new issue