From 7077e7d58f4fdb81160c8ceddf7120973e8314bb Mon Sep 17 00:00:00 2001 From: Rubin Zhang Date: Thu, 1 Feb 2024 23:01:36 +0000 Subject: [PATCH] Add Linux support for scripts (#38) * kill(1) on linux requires pid, fix script exiting * more fixes for kill(1) on linux * fix --- scripts/cli.sh | 2 +- scripts/run_py_dev.sh | 2 +- scripts/run_web_dev.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/cli.sh b/scripts/cli.sh index 5c3fb73eb..c5e23c37d 100755 --- a/scripts/cli.sh +++ b/scripts/cli.sh @@ -1,2 +1,2 @@ -lsof -t -i:32123 | xargs kill && \ +(lsof -t -i:32123 | xargs kill) || true && \ ibazel run //mesop/cli -- --path="mesop/mesop/example_index.py" diff --git a/scripts/run_py_dev.sh b/scripts/run_py_dev.sh index d4602c6dd..87f97006a 100755 --- a/scripts/run_py_dev.sh +++ b/scripts/run_py_dev.sh @@ -1,2 +1,2 @@ -lsof -t -i:32123 | xargs kill && \ +(lsof -t -i:32123 | xargs kill) || true && \ ibazel run //mesop/cli:dev_cli -- --path="mesop/mesop/example_index.py" diff --git a/scripts/run_web_dev.sh b/scripts/run_web_dev.sh index fa9955073..d0a45bb4e 100755 --- a/scripts/run_web_dev.sh +++ b/scripts/run_web_dev.sh @@ -1,2 +1,2 @@ -lsof -t -i:4200 | xargs kill && \ +(lsof -t -i:4200 | xargs kill) || true && \ MESOP_SERVER_HOST="http://localhost:32123" ibazel run //mesop/web/src/app/dev:server