opencode icon indicating copy to clipboard operation
opencode copied to clipboard

nix: prune bun platform binaries from package

Open ry2009 opened this issue 2 weeks ago • 2 comments

  • Fixed the prune step so it actually works in Nix builds (copied .bun tree is read-only): nix/opencode.nix:96 now chmod -R u+w "$bun_root" before the rm -rf.
  • Fixed the Nix interpolation bug by escaping shell ${...} expansions (''${...}) in nix/opencode.nix:99, so nix build doesn’t fail to parse.
  • Verified with a real nixos/nix Docker build for aarch64-linux: output went from ~4.2 GiB (baseline) down to 2.8 GiB.

ry2009 avatar Jan 03 '26 05:01 ry2009