From 4b20abc38910e98d80234e9211bc366305ee094f Mon Sep 17 00:00:00 2001 From: Sanskar Tiwari Date: Sat, 20 May 2023 19:37:01 +0530 Subject: [PATCH 1/3] add batch file to update and start --- UpdateAndStart.bat | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 UpdateAndStart.bat diff --git a/UpdateAndStart.bat b/UpdateAndStart.bat new file mode 100644 index 000000000..261f13c33 --- /dev/null +++ b/UpdateAndStart.bat @@ -0,0 +1,16 @@ +@echo off +pushd %~dp0 +git --version > nul 2>&1 +if %errorlevel% neq 0 ( + echo Git is not installed on this system. Skipping update. +) else ( + call git pull + if %errorlevel% neq 0 ( + REM incase we get merge conflicts or something + echo There were errors while updating. Please download the latest version manually. + ) +) +call npm install +node server.js +pause +popd \ No newline at end of file From 9a537c8a14263913a085df75e8dc4aad3ebe49fd Mon Sep 17 00:00:00 2001 From: Sanskar Tiwari Date: Sat, 20 May 2023 21:07:28 +0530 Subject: [PATCH 2/3] add flags, lf, eof newline --- UpdateAndStart.bat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UpdateAndStart.bat b/UpdateAndStart.bat index 261f13c33..803a8c951 100644 --- a/UpdateAndStart.bat +++ b/UpdateAndStart.bat @@ -4,7 +4,7 @@ git --version > nul 2>&1 if %errorlevel% neq 0 ( echo Git is not installed on this system. Skipping update. ) else ( - call git pull + call git pull --rebase --autostash if %errorlevel% neq 0 ( REM incase we get merge conflicts or something echo There were errors while updating. Please download the latest version manually. From 46e26dbf443e123b25bc017652dfd5f3caad004e Mon Sep 17 00:00:00 2001 From: Sanskar Tiwari Date: Sat, 20 May 2023 21:08:04 +0530 Subject: [PATCH 3/3] add flags, lf, eof newline --- UpdateAndStart.bat | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/UpdateAndStart.bat b/UpdateAndStart.bat index 803a8c951..3f1d3a93c 100644 --- a/UpdateAndStart.bat +++ b/UpdateAndStart.bat @@ -6,11 +6,11 @@ if %errorlevel% neq 0 ( ) else ( call git pull --rebase --autostash if %errorlevel% neq 0 ( - REM incase we get merge conflicts or something + REM incase there is still something wrong echo There were errors while updating. Please download the latest version manually. ) ) call npm install node server.js pause -popd \ No newline at end of file +popd