From abff04fe71d29be41875db1173a554fb11c67173 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Wed, 5 Apr 2023 09:13:44 +0200 Subject: replace depreceated deno bundle with esbuild --- client-web/makefile | 10 ++++++---- makefile | 4 ++++ 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/client-web/makefile b/client-web/makefile index 2623c6e..2ff29d5 100644 --- a/client-web/makefile +++ b/client-web/makefile @@ -1,12 +1,14 @@ +ESFLAGS = --bundle --target=esnext --format=esm + .PHONY: all watch all: public/assets/bundle.js public/assets/sw.js public/assets/font/include.css watch: - deno bundle --no-check --watch source/index.ts public/assets/bundle.js & - deno bundle --no-check --watch source/sw/worker.ts public/assets/sw.js + esbuild $(ESFLAGS) source/index.ts --outfile=public/assets/bundle.js --watch=forever & + esbuild $(ESFLAGS) source/sw/worker.ts --outfile=public/assets/sw.js --watch=forever public/assets/bundle.js: $(shell find source -type f -name '*.ts') - deno bundle --no-check --unstable source/index.ts > $@ + esbuild $(ESFLAGS) source/index.ts --outfile=$@ public/assets/sw.js: $(shell find source/sw -type f -name '*.ts') - deno bundle --no-check --unstable source/sw/worker.ts > $@ + esbuild $(ESFLAGS) source/sw/worker.ts --outfile=$@ public/assets/font/include.css: mkdir -p public/assets/font curl 'https://s.metamuffin.org/static/font-ubuntu.tar' | tar -xC public/assets/font diff --git a/makefile b/makefile index 0ecad9c..d0a1719 100644 --- a/makefile +++ b/makefile @@ -15,6 +15,10 @@ watch: watch-public: make -C client-web watch & make -C server watch-public +kill-watch: + pkill esbuild || true + pkill cargo || true + pkill make || true install-server: client-build cargo +nightly install --force --path server --features standalone install-native: -- cgit v1.2.3-70-g09d2