docs: 增加一键安装脚本并优化 ignore 配置
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -9,6 +9,7 @@ data/
|
|||||||
# Exports (Contains sensitive information)
|
# Exports (Contains sensitive information)
|
||||||
accounts_export.txt
|
accounts_export.txt
|
||||||
export.js
|
export.js
|
||||||
|
一键导出账号.bat
|
||||||
|
|
||||||
# OS files
|
# OS files
|
||||||
.DS_Store
|
.DS_Store
|
||||||
|
|||||||
38
一键安装环境.bat
Normal file
38
一键安装环境.bat
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
@echo off
|
||||||
|
setlocal enabledelayedexpansion
|
||||||
|
|
||||||
|
echo ==========================================
|
||||||
|
echo 2FA 账号工具 - 一键环境安装
|
||||||
|
echo ==========================================
|
||||||
|
echo.
|
||||||
|
|
||||||
|
:: 检查 Node.js 是否安装
|
||||||
|
node -v >nul 2>&1
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo [错误] 未检测到 Node.js 环境!
|
||||||
|
echo 请先安装 Node.js (建议 LTS 版本): https://nodejs.org/
|
||||||
|
pause
|
||||||
|
exit /b
|
||||||
|
)
|
||||||
|
|
||||||
|
echo [1/2] 正在清理旧的依赖缓存...
|
||||||
|
if exist node_modules (
|
||||||
|
rd /s /q node_modules
|
||||||
|
)
|
||||||
|
|
||||||
|
echo [2/2] 正在安装项目依赖...
|
||||||
|
call npm install
|
||||||
|
|
||||||
|
if %errorlevel% neq 0 (
|
||||||
|
echo.
|
||||||
|
echo [错误] 依赖安装失败,请检查网络连接。
|
||||||
|
pause
|
||||||
|
exit /b
|
||||||
|
)
|
||||||
|
|
||||||
|
echo.
|
||||||
|
echo ==========================================
|
||||||
|
echo 安装完成!现在可以运行 start.vbs 启动应用。
|
||||||
|
echo ==========================================
|
||||||
|
echo.
|
||||||
|
pause
|
||||||
Reference in New Issue
Block a user