-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4731065
commit 21fc363
Showing
3 changed files
with
45 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
@echo off | ||
|
||
REM Check if score.txt has been modified | ||
git diff --quiet HEAD score.txt | ||
if %errorlevel% == 0 ( | ||
echo No changes in score.txt, skipping update. | ||
exit /b 0 | ||
) | ||
|
||
REM If we're here, score.txt has been modified | ||
echo Pushing score to GitHub... | ||
git add score.txt | ||
git commit -m "[Auto]Update score" | ||
git push origin master |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/bin/bash | ||
set -e | ||
|
||
# Check if score.txt has been modified | ||
if git diff --quiet HEAD score.txt; then | ||
echo "No changes in score.txt, skipping update." | ||
exit 0 | ||
fi | ||
|
||
# If we're here, score.txt has been modified | ||
echo "Pushing score to GitHub..." | ||
git add score.txt | ||
git commit -m "[Auto]Update score" | ||
git push origin master |