#!/bin/sh set -e run_exe=0 if [ "$1" = "run" ]; then run_exe=1 fi if ! [ -d ".git" ]; then echo "Run in the project root" exit 1 fi mkdir -p build cd build || exit cmake .. make if [ ${run_exe} -eq 1 ]; then ./server/simworld-daemon "$@" fi cd ..