update the make files to not use trunk

This commit is contained in:
Jeremy Wall 2022-06-14 18:42:31 -04:00
parent d0f57894f9
commit f6a25043dc
3 changed files with 13 additions and 7 deletions

View File

@ -18,11 +18,17 @@ kitchen: wasm kitchen/src/*.rs
release: wasmrelease
cd kitchen; cargo build --release
wasmrelease: web/index.html web/src/*.rs web/src/components/*.rs
cd web; trunk build --release --public-url /ui/
static-prep: web/index.html web/static/*.css
mkdir -p web/dist
cp -r web/index.html web/dist/
cp -r web/static web/dist/
wasm: web/index.html web/src/*.rs web/src/components/*.rs
cd web; trunk build --public-url /ui/
wasmrelease: static-prep web/src/*.rs web/src/components/*.rs
cd web; wasm-pack build --release --target web --out-dir dist/
wasm: static-prep web/src/*.rs web/src/components/*.rs
cd web; wasm-pack build --target web --out-dir dist/
clean:
rm -rf web/dist/*
rm -rf web/dist/*
cargo clean

View File

@ -58,7 +58,7 @@
program = "${kitchen}/bin/kitchen";
};
devShell = pkgs.mkShell {
buildInputs = [ rust-wasm ] ++ (with pkgs; [wasm-bindgen-cli wasm-pack]);
buildInputs = [ rust-wasm ] ++ (with pkgs; [wasm-bindgen-cli wasm-pack httplz]);
};
}
);

View File

@ -26,7 +26,7 @@ stdenv.mkDerivation {
mkdir -p $out
cd web
cp -r static $out
wasm-pack build --target web --out-dir $out;
wasm-pack build --release --target web --out-dir $out;
cp -r index.html $out
'';
}