-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path00_install-windows.bat
More file actions
91 lines (81 loc) · 2.15 KB
/
Copy path00_install-windows.bat
File metadata and controls
91 lines (81 loc) · 2.15 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
@echo off
chcp 65001 >nul 2>&1
title Installing Dependencies
echo.
echo ========================================
echo Checking Node.js installation...
echo ========================================
echo.
where node >nul 2>&1
if %ERRORLEVEL% NEQ 0 (
echo [ERROR] Node.js is not installed!
echo.
echo Please install Node.js from the official website:
echo.
echo https://nodejs.org/
echo.
echo Download the LTS version and run the installer.
echo After installation, restart this script.
echo.
pause
exit /b 1
)
for /f "tokens=*" %%i in ('node -v') do set NODE_VERSION=%%i
echo [OK] Node.js found: %NODE_VERSION%
echo.
echo ========================================
echo Installing dependencies...
echo ========================================
echo.
echo [1/4] Installing main dependencies...
call npm install --no-audit --no-fund --loglevel=error
if %ERRORLEVEL% NEQ 0 (
echo.
echo [ERROR] Failed to install main dependencies!
echo.
pause
exit /b 1
)
echo.
echo [2/4] Installing panel dependencies...
call npm --prefix panel install --no-audit --no-fund --loglevel=error
if %ERRORLEVEL% NEQ 0 (
echo.
echo [ERROR] Failed to install panel dependencies!
echo.
pause
exit /b 1
)
echo.
echo [3/4] Installing panel frontend dependencies...
call npm --prefix panel\frontend install --no-audit --no-fund --loglevel=error
if %ERRORLEVEL% NEQ 0 (
echo.
echo [ERROR] Failed to install panel frontend dependencies!
echo.
pause
exit /b 1
)
echo.
echo [4/4] Building panel frontend...
call npm --prefix panel\frontend run build
if %ERRORLEVEL% NEQ 0 (
echo.
echo [ERROR] Failed to build panel frontend!
echo.
pause
exit /b 1
)
if not exist .env (
copy .env.example .env >nul
del .env.example >nul 2>&1
echo.
echo [OK] .env file created from .env.example
echo Please open .env and paste your wallet private key.
)
echo.
echo ========================================
echo Installation completed!
echo ========================================
echo.
pause