Add and use a simpler run script

This commit is contained in:
Michael Wolf
2026-01-01 14:08:46 -06:00
parent 615cd89656
commit 1083655a3b
2 changed files with 3 additions and 26 deletions

View File

@@ -1,32 +1,9 @@
#!/bin/bash
# XXX should we default to strict or non-strict here?
set -eu
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
run_dir="$DIR"
cd "$DIR"
source "$run_dir"/../framework/shims/common
source "$run_dir"/../framework/shims/node.common
strict_arg="${1:---no-strict}"
if [[ "$strict_arg" = "--strict" ]] ; then
strict="yes"
else
strict="no"
fi
cmd="tsx"
if [[ "strict" = "yes" ]] ; then
cmd="ts-node"
fi
cd "$run_dir"
"$run_dir"/check.sh
#echo checked
# $ROOT/cmd "$cmd" $run_dir/app.ts
../cmd node "$run_dir"/out/app.js
exec ../cmd node dist/index.js

View File

@@ -16,7 +16,7 @@ func runExpress(changes <-chan FileChange) {
// Helper to start the express process
startExpress := func() *exec.Cmd {
cmd := exec.Command("node", "../express/dist/index.js")
cmd := exec.Command("../express/run.sh")
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr