forked from theantipopau/omencore
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathupload-to-github.bat
More file actions
105 lines (94 loc) · 2.79 KB
/
upload-to-github.bat
File metadata and controls
105 lines (94 loc) · 2.79 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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
@echo off
REM OmenCore GitHub Upload Script (Windows)
echo =========================================
echo OmenCore GitHub Upload Script
echo =========================================
echo.
REM Check if git is installed
where git >nul 2>nul
if %ERRORLEVEL% NEQ 0 (
echo Error: Git is not installed or not in PATH
echo Please install Git from https://git-scm.com/
pause
exit /b 1
)
REM Check if git is initialized
if not exist ".git" (
echo Initializing Git repository...
git init
echo [OK] Git initialized
) else (
echo [OK] Git repository already initialized
)
REM Check for .gitignore
if not exist ".gitignore" (
echo Error: .gitignore not found!
pause
exit /b 1
)
REM Stage all files
echo.
echo Staging files...
git add .
echo [OK] Files staged
REM Check if there are changes to commit
git diff --staged --quiet
if %ERRORLEVEL% EQU 0 (
echo [WARNING] No changes to commit
) else (
REM Commit
echo.
echo Committing changes...
git commit -m "Initial OmenCore commit - v1.0.0" -m "" -m "Features:" -m "- Fan & thermal control with custom curves" -m "- CPU undervolting support" -m "- RGB lighting profiles" -m "- Hardware monitoring" -m "- Corsair/Logitech device integration" -m "- Auto-update via GitHub releases" -m "- HP Omen system detection" -m "- System optimization tools"
echo [OK] Changes committed
)
REM Check if remote exists
git remote get-url origin >nul 2>nul
if %ERRORLEVEL% EQU 0 (
echo [OK] Remote 'origin' already configured
) else (
echo.
echo Adding remote repository...
git remote add origin https://github.com/theantipopau/omencore.git
echo [OK] Remote added
)
REM Set main branch
echo.
echo Setting main branch...
git branch -M main
echo [OK] Branch set to main
REM Push to GitHub
echo.
echo Pushing to GitHub...
echo You may be prompted for your GitHub credentials...
echo.
git push -u origin main
if %ERRORLEVEL% EQU 0 (
echo.
echo =========================================
echo [OK] Successfully uploaded to GitHub!
echo =========================================
echo.
echo Repository: https://github.com/theantipopau/omencore
echo.
echo Next steps:
echo 1. Create first release: git tag v1.0.0 ^&^& git push origin v1.0.0
echo 2. GitHub Actions will automatically build and publish
echo 3. Users can then auto-update from within the app
echo.
) else (
echo.
echo =========================================
echo [X] Push failed
echo =========================================
echo.
echo Possible issues:
echo - GitHub credentials not configured
echo - Repository doesn't exist (create it at github.com/theantipopau/omencore)
echo - Network connectivity problems
echo.
echo Try manually:
echo git push -u origin main
echo.
)
pause