Skip to content

Commit 2aeeae5

Browse files
committed
Make BrowserProxy.rc for /f friendly, and add an after_build step to appveyor.yml which creates an SFX installer
1 parent a463f98 commit 2aeeae5

File tree

5 files changed

+30
-0
lines changed

5 files changed

+30
-0
lines changed

BrowserProxy/BrowserProxy.rc

-3.1 KB
Binary file not shown.

Installer/MakeSFX.exe

432 KB
Binary file not shown.

Installer/MakeSetup.bat

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
@echo off
2+
REM Read the version number from the resource file
3+
for /F "tokens=1,2" %%G in (%~dp0..\BrowserProxy\BrowserProxy.rc) do if "%%G" == "FILEVERSION" set FILEVERSION=%%H
4+
echo FILEVERSION=%FILEVERSION:,=.%
5+
REM Create the ZIP
6+
del "%~dp0OpennessWebView2.zip"
7+
"%ProgramFiles%\7-zip\7z.exe" a -mx9 "%~dp0OpennessWebView2.zip" "%~dp0..\BrowserProxy\Release\*.dll" "%~dp0..\LICENSE.md" "%~dp0setup.bat"
8+
REM Create the SFX
9+
"%~dp0makesfx.exe" ^
10+
/zip="%~dp0OpennessWebView2.zip" ^
11+
/sfx="%~dp0OpennessWebView2.exe" ^
12+
/title="OpennessWebView2 Control" ^
13+
/website="https://github.com/datadiode/webview2" ^
14+
/intro="Version: %FILEVERSION:,=.%\n\nThis ActiveX control embeds Microsoft Edge WebView2\ninto SIMATIC WinCC Runtime Advanced.\n\nThe Microsoft Edge WebView2 Runtime needs to be\ninstalled to use this control." ^
15+
/runelevated ^
16+
/overwrite ^
17+
/exec="\"cmd.exe\" /c setup.bat $cmdline$" ^
18+
/defaultpath="$programfiles$\OpennessWebView2"

Installer/setup.bat

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
@echo off
2+
if /i not "%~x2" == ".cab" goto :register
3+
expand.exe -f:* %2 .
4+
echo [OpennessWebView2.dll] > OpennessWebView2.ini
5+
echo BrowserExecutableFolder=%~dp0%~n2 >> OpennessWebView2.ini
6+
:register
7+
regsvr32.exe OpennessWebView2.dll
8+
del %0

appveyor.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,9 @@ build:
1313
verbosity: minimal
1414
project: BrowserProxy.sln
1515

16+
after_build:
17+
- Installer\MakeSetup.bat
18+
1619
artifacts:
1720
- path: BrowserProxy\$(configuration)\OpennessWebView2.dll
21+
- path: Installer\OpennessWebView2.exe

0 commit comments

Comments
 (0)