-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpushToMain.bat
More file actions
34 lines (30 loc) · 816 Bytes
/
Copy pathpushToMain.bat
File metadata and controls
34 lines (30 loc) · 816 Bytes
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
@echo off
echo ========================================
echo Push to Main Branch
echo ========================================
echo.
git branch --show-current
git status --short
git add .
git diff --staged --quiet
if %errorlevel% neq 0 (
git commit -m "push from .bat"
git push origin main
echo.
echo ========================================
echo [SUCCESS] Push to main branch completed!
echo.
echo This will trigger:
echo - GitHub Actions workflow
echo - Automatic deployment to production
echo ========================================
) else (
echo No changes to commit.
echo Working directory is clean.
echo.
echo ========================================
echo [INFO] Nothing to push
echo ========================================
)
echo.
pause