ci: Gitea Actions 定时自动打包发布 + 安装包支持卸载注册
- .gitea/workflows/auto-release.yml:每周一 cron + 手动触发,自动检查 dsh 最新版、 打包 online 安装包、创建 Release 并上传附件(push 触发为临时验证用) - install.cmd 加入仓库:安装时注册 Windows 卸载项(配合 uninstall.vbs)
This commit is contained in:
1 parent
880915bf01
commit
4dcb8a29f5
2 files changed
+125
No files matched your search
+61
@@ -0,0 +1,61 @@
|
||||
@echo off
|
||||
setlocal
|
||||
title DeepSeek Harness Installer (Online)
|
||||
|
||||
echo ============================================
|
||||
echo DeepSeek Harness Desktop - Online Install
|
||||
echo ============================================
|
||||
echo.
|
||||
|
||||
REM ---- 1. Node.js ----
|
||||
where node >nul 2>nul
|
||||
if %errorlevel%==0 (
|
||||
echo [1/5] Node.js detected
|
||||
goto node_ok
|
||||
)
|
||||
echo [1/5] Node.js not found, installing via winget...
|
||||
winget install --id OpenJS.NodeJS.LTS -e --accept-source-agreements --accept-package-agreements
|
||||
if %errorlevel% neq 0 (
|
||||
echo.
|
||||
echo [ERROR] Node.js install failed. Please install manually from https://nodejs.org (LTS), then run this script again.
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
set "PATH=%PATH%;C:\Program Files\nodejs;%APPDATA%\npm"
|
||||
:node_ok
|
||||
|
||||
REM ---- 2. npm registry (mirror for speed) ----
|
||||
echo [2/5] Setting npm mirror registry...
|
||||
call npm config set registry https://registry.npmmirror.com
|
||||
|
||||
REM ---- 3. Install dsh ----
|
||||
echo [3/5] Installing DeepSeek Harness (dsh)...
|
||||
call npm install -g @deepseek-ai/dsh
|
||||
if %errorlevel% neq 0 (
|
||||
echo.
|
||||
echo [ERROR] dsh install failed. Check network and retry.
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
REM ---- 4. Deploy app ----
|
||||
echo [4/5] Deploying application...
|
||||
set "DEST=%LOCALAPPDATA%\DeepSeekHarness"
|
||||
if not exist "%DEST%" mkdir "%DEST%"
|
||||
xcopy /E /I /Y app "%DEST%\app" >nul
|
||||
copy /Y dsh.ico "%DEST%\" >nul
|
||||
copy /Y README.md "%DEST%\" >nul
|
||||
|
||||
REM ---- 5. Register uninstall (Apps & Features) ----
|
||||
echo [5/5] Registering uninstall entry...
|
||||
copy /Y uninstall.vbs "%DEST%\" >nul
|
||||
copy /Y register-uninstall.ps1 "%DEST%\" >nul
|
||||
powershell -NoProfile -ExecutionPolicy Bypass -File "%DEST%\register-uninstall.ps1"
|
||||
|
||||
REM ---- 6. Desktop shortcut ----
|
||||
powershell -NoProfile -ExecutionPolicy Bypass -Command "$s=(New-Object -ComObject WScript.Shell).CreateShortcut([Environment]::GetFolderPath('Desktop')+'\DeepSeek Harness.lnk');$s.TargetPath='%DEST%\app\dsh-app.exe';$s.IconLocation='%DEST%\dsh.ico,0';$s.WorkingDirectory='%DEST%\app';$s.Save()"
|
||||
|
||||
echo.
|
||||
echo Install complete! Launching...
|
||||
start "" "%DEST%\app\dsh-app.exe"
|
||||
pause
|
||||
Reference in new issue
Block a user