-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpush_to_github.bat
More file actions
66 lines (57 loc) · 1.59 KB
/
push_to_github.bat
File metadata and controls
66 lines (57 loc) · 1.59 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
@echo off
echo.
echo ========================================
echo GitHub Push Helper - Crafted by Yukthesh
echo ========================================
echo.
set /p username="Enter your GitHub username: "
set /p repo_name="Enter repository name (e.g., StreetScan-AI): "
if "%username%"=="" (
echo Error: Username is required!
pause
exit /b 1
)
if "%repo_name%"=="" (
echo Error: Repository name is required!
pause
exit /b 1
)
echo.
echo Repository Details:
echo Username: %username%
echo Repository: %repo_name%
echo Remote URL: https://github.com/%username%/%repo_name%.git
echo.
set /p confirm="Proceed with pushing to GitHub? (y/N): "
if /i not "%confirm%"=="y" (
echo Push cancelled by user
pause
exit /b 0
)
echo.
echo Adding remote repository...
git remote add origin https://github.com/%username%/%repo_name%.git
if errorlevel 1 (
echo Remote might already exist, updating URL...
git remote set-url origin https://github.com/%username%/%repo_name%.git
)
echo.
echo Pushing to GitHub...
git push -u origin master
if errorlevel 1 (
echo.
echo Failed to push to GitHub. Please check:
echo 1. Repository exists on GitHub
echo 2. You have write permissions
echo 3. Your GitHub credentials are correct
) else (
echo.
echo ========================================
echo Successfully pushed to GitHub!
echo ========================================
echo.
echo View your repository at: https://github.com/%username%/%repo_name%
echo.
echo Your RTSP Vehicle Detection System is now live with Yukthesh branding!
)
pause