Sync translations from Transifex and run lupdate
[qBittorrent.git] / dist / windows / 3rdparty / VersionCompleteXXXX.nsi
blobbb5ca9d024b631f0a8b2507cbe6fb9873e3991fc
1 ; Code taken from https://nsis.sourceforge.io/VersionCompleteXXXX
2 ; See http://nsis.sourceforge.net/VersionCompleteXXXX for documentation
3 !macro VersionCompleteXXXRevision _INPUT_VALUE _OUTPUT_SYMBOL _REVISION
4 !searchparse /noerrors ${_INPUT_VALUE} "" _VERSION_1 "." _VERSION_2 "." _VERSION_3 "." _VERSION_4
5 !ifndef _VERSION_1
6 !define _VERSION_1 0
7 !else if `${_VERSION_1}` == ``
8 !define /redef _VERSION_1 0
9 !endif
10 !ifndef _VERSION_2
11 !define _VERSION_2 0
12 !else if `${_VERSION_2}` == ``
13 !define /redef _VERSION_2 0
14 !endif
15 !ifndef _VERSION_3
16 !define _VERSION_3 0
17 !else if `${_VERSION_3}` == ``
18 !define /redef _VERSION_3 0
19 !endif
20 !ifndef _VERSION_4
21 !define _VERSION_4 0
22 !else if `${_VERSION_4}` == ``
23 !define /redef _VERSION_4 0
24 !endif
25 !define ${_OUTPUT_SYMBOL} ${_VERSION_1}.${_VERSION_2}.${_VERSION_3}.${_REVISION}
26 !undef _VERSION_1
27 !undef _VERSION_2
28 !undef _VERSION_3
29 !undef _VERSION_4
30 !undef _REVISION
31 !macroend
32 !define VersionCompleteXXXRevision `!insertmacro VersionCompleteXXXRevision`
33 !macro VersionCompleteXXXX _INPUT_VALUE _OUTPUT_SYMBOL
34 !searchparse /noerrors ${_INPUT_VALUE} "" _VERSION_1 "." _VERSION_2 "." _VERSION_3 "." _VERSION_4
35 !ifndef _VERSION_1
36 !define _VERSION_1 0
37 !else if `${_VERSION_1}` == ``
38 !define /redef _VERSION_1 0
39 !endif
40 !ifndef _VERSION_2
41 !define _VERSION_2 0
42 !else if `${_VERSION_2}` == ``
43 !define /redef _VERSION_2 0
44 !endif
45 !ifndef _VERSION_3
46 !define _VERSION_3 0
47 !else if `${_VERSION_3}` == ``
48 !define /redef _VERSION_3 0
49 !endif
50 !ifndef _VERSION_4
51 !define _VERSION_4 0
52 !else if `${_VERSION_4}` == ``
53 !define /redef _VERSION_4 0
54 !endif
55 !define ${_OUTPUT_SYMBOL} ${_VERSION_1}.${_VERSION_2}.${_VERSION_3}.${_VERSION_4}
56 !undef _VERSION_1
57 !undef _VERSION_2
58 !undef _VERSION_3
59 !undef _VERSION_4
60 !macroend
61 !define VersionCompleteXXXX `!insertmacro VersionCompleteXXXX`