@echo off REM ============================================================ REM 一键推送本地提交到 Gitea REM 使用前提:本机能访问公司内网 / 已连 VPN,能解析 git.btw-ocr.com REM Gitea 凭据由系统凭据助手(helper-selector / GCM)提供,无需手填 REM ============================================================ cd /d "D:\2026-09-10-task-20\material_wms" echo [1/3] 拉取远程最新... git fetch origin if %errorlevel% neq 0 ( echo fetch 失败:请确认已连内网/VPN,且能访问 git.btw-ocr.com pause exit /b 1 ) echo [2/3] 将本地提交 rebase 到远程 main 之上... git rebase origin/main if %errorlevel% neq 0 ( echo rebase 冲突:请手动解决冲突后 git rebase --continue,或运行 git rebase --abort 撤销 pause exit /b 1 ) echo [3/3] 推送到 Gitea... git push origin main if %errorlevel% neq 0 ( echo push 失败,请检查凭据或网络后重试 pause exit /b 1 ) echo. echo ===== 推送完成 ===== echo 可在 https://git.btw-ocr.com/star/Inventory-Management-System 核对最新提交 pause