-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild-protected.bat
More file actions
43 lines (38 loc) · 1.14 KB
/
Copy pathbuild-protected.bat
File metadata and controls
43 lines (38 loc) · 1.14 KB
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
@echo off
echo ========================================
echo ControlWorkbench Build and Obfuscate
echo ========================================
echo.
cd /d "%~dp0"
echo [1/4] Building Release...
dotnet build -c Release
if errorlevel 1 (
echo BUILD FAILED!
pause
exit /b 1
)
echo.
echo [2/4] Checking for ConfuserEx...
if not exist "%TEMP%\ConfuserEx\Confuser.CLI.exe" (
echo Downloading ConfuserEx...
powershell -Command "Invoke-WebRequest -Uri 'https://github.com/mkaring/ConfuserEx/releases/download/v1.6.0/ConfuserEx-CLI.zip' -OutFile '%TEMP%\ConfuserEx.zip'"
powershell -Command "Expand-Archive -Path '%TEMP%\ConfuserEx.zip' -DestinationPath '%TEMP%\ConfuserEx' -Force"
)
echo.
echo [3/4] Obfuscating...
"%TEMP%\ConfuserEx\Confuser.CLI.exe" "ControlWorkbench.App\ConfuserEx.crproj"
if errorlevel 1 (
echo OBFUSCATION FAILED!
echo.
echo Note: ConfuserEx may not fully support .NET 8.
echo Your Release build is still available at:
echo ControlWorkbench.App\bin\Release\net8.0-windows\
pause
exit /b 1
)
echo.
echo [4/4] Done!
echo.
echo Obfuscated files are in: ControlWorkbench.App\Confused\
echo.
pause