From 4ccaa3c849070379f52e6b306811ca33305d0694 Mon Sep 17 00:00:00 2001 From: LLLL Colonq Date: Sun, 8 Jun 2025 04:02:18 -0400 Subject: Add wasm.buildAtUrl --- flake.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/flake.nix b/flake.nix index e1f4ba5..850caa0 100644 --- a/flake.nix +++ b/flake.nix @@ -89,7 +89,7 @@ }; wasm = rec { - build = path: nm: + buildAtUrl = path: nm: url: let src = lib.cleanSourceWith { src = path; @@ -124,11 +124,13 @@ craneLib.buildTrunkPackage (commonArgs // rec { pname = nm; cargoExtraArgs = "-p ${nm}"; + trunkExtraBuildArgs = "--public-url ${url}"; cargoArtifacts = craneLib.buildDepsOnly (commonArgs // { inherit cargoExtraArgs; doCheck = false; }); }); + build = path: nm: buildAtUrl path nm ""; }; windows = rec { -- cgit v1.2.3