integrate build scripts; build before publish

This commit is contained in:
Scott Richmond 2024-06-07 15:20:36 -04:00
parent 9498bed710
commit f2d76e766b
2 changed files with 10 additions and 2 deletions

View File

@ -1,6 +1,4 @@
build: build:
# compile the janet into an image
# janet -c src/ludus.janet build/ludus.jimage
# the complex emscripten invocation # the complex emscripten invocation
# note we have the stack size set to 1024*1024 (1 MB) # note we have the stack size set to 1024*1024 (1 MB)
emcc \ emcc \

View File

@ -3,6 +3,7 @@ repl:
kitten @ launch --type=os-window --allow-remote-control --cwd=current --title=hx_repl:ludus --keep-focus kitten @ launch --type=os-window --allow-remote-control --cwd=current --title=hx_repl:ludus --keep-focus
kitten @ send-text -m "title:hx_repl:ludus" "janet -s\n" kitten @ send-text -m "title:hx_repl:ludus" "janet -s\n"
# restart the repl server
restart: restart:
kitten @ send-text -m "title:hx_repl:ludus" "\04" kitten @ send-text -m "title:hx_repl:ludus" "\04"
kitten @ send-text -m "title:hx_repl:ludus" "janet -s\n" kitten @ send-text -m "title:hx_repl:ludus" "janet -s\n"
@ -17,5 +18,14 @@ doc:
# publish to npm (did you build things first?) # publish to npm (did you build things first?)
publish: publish:
just build
npm version patch npm version patch
npm publish npm publish
# build the ludus jimage
build:
rm build/out.mjs
rm build/out.wasm
rm build/ludus.jimage
janet -c src/ludus.janet build/ludus.jimage
cd build && just build