summaryrefslogtreecommitdiffstats
path: root/scripts/debug.sh
diff options
context:
space:
mode:
authorJan Tuomi <jan.tuomi@valuemotive.com>2021-10-29 15:22:09 +0300
committerJan Tuomi <jan.tuomi@valuemotive.com>2021-10-29 15:22:09 +0300
commitf4dacee4908300f63200864b9f089874152a568c (patch)
tree38102b52e258531f197a3454492448b57a16acb6 /scripts/debug.sh
parentd0b6988a1a49ae0966e887e892508f2afc12bc6a (diff)
Add scripts
Diffstat (limited to 'scripts/debug.sh')
-rwxr-xr-xscripts/debug.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/scripts/debug.sh b/scripts/debug.sh
new file mode 100755
index 0000000..0ae14a3
--- /dev/null
+++ b/scripts/debug.sh
@@ -0,0 +1,9 @@
+#!/bin/bash
+
+TOP_LEVEL="$(git rev-parse --show-toplevel)"
+PORT="${1:-8001}"
+
+echo ":: Watching directory src/ and serving continuous builds on http://localhost:${PORT}"
+
+bash scripts/_build-and-serve.sh ${PORT}
+fswatch -or src | xargs -n1 -I{} bash scripts/_build-and-serve.sh ${PORT}