tarball: add --show-trace to nix-env command

Otherwise, when this fails on Hydra, we have no way of seeing what
went wrong, e.g. [1].

[1]: https://hydra.nixos.org/log/2210x8gsd8jgdx73qa7hmhmmridyy7yp-nixpkgs-tarball-23.05pre450719.c11c55dd08a.drv

Suggested-by: K900 <me@0upti.me>
This commit is contained in:
Alyssa Ross 2023-02-02 18:11:10 +00:00
parent dc109a3192
commit 9d75205879
No known key found for this signature in database
GPG Key ID: F9DBED4859B271C0

View File

@ -64,7 +64,7 @@ pkgs.releaseTools.sourceTarball {
echo "generating packages.json"
mkdir -p $out/nix-support
echo -n '{"version":2,"packages":' > tmp
nix-env -f . -I nixpkgs=$src -qa --meta --json --arg config 'import ${./packages-config.nix}' "''${opts[@]}" >> tmp
nix-env -f . -I nixpkgs=$src -qa --meta --json --show-trace --arg config 'import ${./packages-config.nix}' "''${opts[@]}" >> tmp
echo -n '}' >> tmp
packages=$out/packages.json.br
< tmp sed "s|$(pwd)/||g" | jq -c | brotli -9 > $packages