File: localize.bat

package info (click to toggle)
lazarus 2.0.2+dfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 215,992 kB
  • sloc: pascal: 1,863,844; xml: 265,709; cpp: 56,595; sh: 3,008; java: 609; makefile: 533; perl: 297; sql: 222; ansic: 137
file content (68 lines) | stat: -rw-r--r-- 1,592 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
@echo off
REM
REM Make sure you have your setings correctly
REM
REM Usage: localize
REM
REM This script should be executed after adding new resource strings and after
REM udating the translated .po files.
REM
REM This script
REM - converts all compiled .rsj (.rst if .rsj is not found) files to .po files,
REM - updates all translated xx.po files
REM

REM set LazInstall=C:\lazarus\
set ArchOS=i386-win32
set ArchOsWS=%ArchOS%\win32

echo.

REM Compile tools if updatepofiles is missing

if exist tools\updatepofiles.exe goto SkipTools
echo The updatepofiles tool was not found, compiling tools ...
echo.
cd tools
make updatepofiles.exe
cd..
if not exist tools\updatepofiles.exe goto Exit_Error

:SkipTools

echo Updating language files ...
echo.

echo on

@echo Updating IDE
@set IDE_RSJ=units\%ArchOsWS%\LazarusIDEStrConsts.rsj
@if exist %IDE_RSJ% goto IDE_update
@echo RSJ file NOT found. Searching for RST.
@set IDE_RSJ=units\%ArchOsWS%\LazarusIDEStrConsts.rst
@if not exist %IDE_RSJ% goto SkipIDE
:IDE_update
@tools\updatepofiles %IDE_RSJ% languages\lazaruside.po
@echo Translation file %IDE_RSJ% found.
:SkipIDE
@echo.

@echo Updating Debugger dialogs
@set DBGD_RSJ=units\%ArchOsWS%\DebuggerStrConst.rsj
@if exist %DBGD_RSJ% goto DBGD_update
@echo RSJ file NOT found. Searching for RST.
@set DBGD_RSJ=units\%ArchOsWS%\DebuggerStrConst.rst
@if not exist %DBGD_RSJ% goto SkipDBGD
:DBGD_update
@tools\updatepofiles %DBGD_RSJ% languages\debuggerstrconst.po
@echo Translation file %DBGD_RSJ% found.
:SkipDBGD
@echo.

@goto Exit

:Exit_Error
echo Unable to compile updatepofiles tool

:Exit