-
Notifications
You must be signed in to change notification settings - Fork 20
/
CreateDistribZip.cmd
68 lines (55 loc) · 1.49 KB
/
CreateDistribZip.cmd
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
setlocal
setlocal enabledelayedexpansion
cd /d %~dp0
set cwd=%cd%
set curdate=%date:~6,4%-%date:~3,2%-%date:~0,2%
set target=%cd%\SteamServerBrowser
mkdir "%target%" 2>nul
del /s /q "%target%\*"
rem find signtool.exe
for /d %%f in ("C:\Program Files (x86)\Windows Kits\10\bin\10.*") do (
set nq=%%f
set nq=!nq:"=!
set signtool="!nq!\x86\signtool.exe"
if exist !signtool! goto foundSigntool
)
echo "can't find signtool.exe"
pause
goto :eof
:foundSigntool
cd "%cwd%\bin\Release"
copy ServerBrowser.exe "%target%"
copy QueryMaster.dll "%target%"
copy Ionic.BZip2.dll "%target%"
copy steam_api.dll "%target%"
copy steam_api64.dll "%target%"
rem del "DevExpress*Rich*"
rem del "DevExpress*Office*"
del "DevExpress*Spark*"
del "DevExpress*Tree*"
copy "DevExpress*.dll" "%target%"
del "%target%\*BonusSkins*"
cd "%target%"
call :CodeSigning
cd "%cwd%"
copy *.md "%target%"
del "%target%.zip" >nul
"c:\program files\7-Zip\7z.exe" a -tzip "%target%.zip" SteamServerBrowser
cd "%cwd%"
pause
goto :eof
@echo off
:CodeSigning
rem -----------------------------
rem If you want to digitally sign the generated .exe and .dll files,
rem you need to have your code signing certificate installed in the Windows certificate storage
rem -----------------------------
set files=ServerBrowser.exe QueryMaster.dll
if not exist %signtool% (
echo %signtool% not found
pause
exit /b 1
)
%signtool% sign /n "ABPro Entwicklungs-, Vertriebs- und Wartungs GmbH" /t "http://timestamp.digicert.com" %files%
goto :eof