summaryrefslogtreecommitdiff
path: root/watch.sh
diff options
context:
space:
mode:
authorWormHeamer2025-10-27 23:41:58 -0400
committerWormHeamer2025-10-27 23:41:58 -0400
commit70ee897904b708d07f3cd0d823b5dad8536a4654 (patch)
tree6c290461f28c0ca88548b5e3b55002dc73f42610 /watch.sh
parent0b5cf5d18142e715f7bba89c21eada34d3f77b54 (diff)
add watch.sh
Diffstat (limited to 'watch.sh')
-rwxr-xr-xwatch.sh14
1 files changed, 14 insertions, 0 deletions
diff --git a/watch.sh b/watch.sh
new file mode 100755
index 0000000..896473d
--- /dev/null
+++ b/watch.sh
@@ -0,0 +1,14 @@
+#!/bin/sh
+
+gen() {
+ tcc ir.c lex.c impl.c peephole.c proc.c -run main.c test.lang\
+ | dot -Tpdf -o out.pdf
+}
+
+gen
+mupdf out.pdf &
+while true; do
+ inotifywait -e modify -r .
+ gen
+ killall -SIGHUP mupdf
+done