-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSetup.bat
More file actions
44 lines (38 loc) · 1.22 KB
/
Setup.bat
File metadata and controls
44 lines (38 loc) · 1.22 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
44
@echo off
set CSC_PATH=C:\Windows\Microsoft.NET\Framework64\v4.0.30319\csc.exe
echo ========================================
echo ImagePaster Pro - Build System
echo ========================================
echo.
:: التأكد من وجود ملف الأيقونة
if not exist "icon.ico" (
echo [ERROR] icon.ico file is missing!
echo Please ensure "icon.ico" exists in this folder.
pause
exit /b
)
echo Preparing for build...
:: إغلاق البرنامج إذا كان يعمل
taskkill /f /im ImagePaster.exe /t >nul 2>&1
timeout /t 1 /nobreak >nul
echo Building ImagePaster Pro with integrated icon...
echo Path: icon.ico -> ImagePaster.exe
"%CSC_PATH%" /target:winexe /win32icon:icon.ico /out:ImagePaster.exe Program.cs
if %ERRORLEVEL% EQU 0 (
echo.
echo ========================================
echo BUILD SUCCESSFUL!
echo Icon has been embedded into EXE
echo ========================================
echo.
echo Starting the application...
start ImagePaster.exe
timeout /t 2 /nobreak >nul
) else (
echo.
echo ========================================
echo BUILD FAILED!
echo Check the errors above.
echo ========================================
pause
)