2025-07-02 14:43:50 +03:00
|
|
|
@echo off
|
|
|
|
|
setlocal
|
|
|
|
|
|
|
|
|
|
:: Define repo paths
|
|
|
|
|
set "SCRIPTS_DIR=%~dp0"
|
|
|
|
|
set "SOUNDS_DIR=%~dp0sounds"
|
|
|
|
|
|
|
|
|
|
:: Try to use system git, fallback to GitPortable
|
|
|
|
|
where git >nul 2>nul
|
|
|
|
|
if %errorlevel%==0 (
|
|
|
|
|
set "GIT=git"
|
|
|
|
|
) else if exist "%~dp0GitPortable\cmd\git.exe" (
|
|
|
|
|
set "GIT=%~dp0GitPortable\cmd\git.exe"
|
|
|
|
|
) else (
|
|
|
|
|
echo Git not found. Please install Git or place GitPortable in the same folder.
|
|
|
|
|
exit /b 1
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
:: Reset scripts repo
|
|
|
|
|
echo Resetting scripts repo to remote...
|
|
|
|
|
pushd "%SCRIPTS_DIR%"
|
2025-07-28 17:01:04 +01:00
|
|
|
call "%GIT%" fetch origin
|
|
|
|
|
call "%GIT%" reset --hard origin/main
|
2025-07-02 14:43:50 +03:00
|
|
|
popd
|
|
|
|
|
|
|
|
|
|
:: Reset sounds repo
|
|
|
|
|
echo Resetting sounds repo to remote...
|
|
|
|
|
pushd "%SOUNDS_DIR%"
|
2025-07-28 17:01:04 +01:00
|
|
|
call "%GIT%" fetch origin
|
|
|
|
|
call "%GIT%" reset --hard origin/main
|
2025-07-02 14:43:50 +03:00
|
|
|
popd
|
|
|
|
|
|
|
|
|
|
echo Done.
|
|
|
|
|
endlocal
|