OSDN Git Service

Properly handle plurals in translation files.
[lamexp/LameXP.git] / etc / Translation / update.bat
index 9f331c9..2e2f59e 100644 (file)
@@ -1,8 +1,9 @@
 @echo off
 REM ---------------------------
-set "QTVARS=E:\Qt\MSVC\4.7.1\bin\qtvars.bat"
+call "..\Deployment\_paths.bat"
+if exist "%PATH_QTMSVC%\bin\qtenv2.bat" call "%PATH_QTMSVC%\bin\qtenv2.bat"
+if exist "%PATH_QTMSVC%\bin\qtvars.bat" call "%PATH_QTMSVC%\bin\qtvars.bat"
 REM ---------------------------
-call "%QTVARS%"
 del update.lst > NUL
 REM ---------------------------
 if exist update.lst (
@@ -23,7 +24,10 @@ for %%f in (..\..\src\*.h) do (
 )
 REM ---------------------------
 for %%f in (*.ts) do (
+       del %%f.bak 2> NUL
+       copy %%f %%f.bak
        lupdate.exe @update.lst -no-obsolete -ts %%f
 )
+lupdate.exe @update.lst -no-obsolete -pluralonly -ts "LameXP_EN.ts"
 REM ---------------------------
 pause