#!/usr/bin/env bash out_dir="$(nix --experimental-features 'nix-command flakes' build --no-link --print-out-paths)" cp -r "$out_dir" ./build # fix permissions that are copied from the nix store chmod +w -R ./build