change update to a more stable version

This commit is contained in:
2020-04-30 23:13:11 +02:00
parent a13edde2ab
commit d12e82347f
2 changed files with 12 additions and 14 deletions

12
start_latest.sh Executable file
View File

@@ -0,0 +1,12 @@
git reset HEAD --hard &&
git pull &&
cd backend &&
rm -r ./frontend &&
mkdir frontend &&
npm i &&
cd ../frontend &&
npm i &&
npm run build &&
mv ./build/* ../backend/frontend &&
cd ../backend &&
npm start

View File

@@ -1,14 +0,0 @@
BACKENDID = netstat -tulpn 2>/dev/null | grep ":3001 " | awk '{print $7;}' | cut -d "/" -f1
kill -9 $BACKENDID
git reset HEAD --hard
git pull
cd backend
rm -r ./frontend
mkdir frontend
npm i
cd ../frontend
npm i
npm run build
mv ./build/* ../backend/frontend
cd ../backend
npm start