From bf81cded7dfda6d27508cc4638befa87cde00838 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Thu, 7 Dec 2023 00:00:56 +0100 Subject: [PATCH] makeNugetSource: symlink files instead of copying them this reduces the closure size of the resulting derivation drastically --- pkgs/build-support/dotnet/make-nuget-source/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/build-support/dotnet/make-nuget-source/default.nix b/pkgs/build-support/dotnet/make-nuget-source/default.nix index ddc2e7b52dbb..48de65e8a881 100644 --- a/pkgs/build-support/dotnet/make-nuget-source/default.nix +++ b/pkgs/build-support/dotnet/make-nuget-source/default.nix @@ -17,7 +17,7 @@ let # use -L to follow symbolic links. When `projectReferences` is used in # buildDotnetModule, one of the deps will be a symlink farm. find -L ${lib.concatStringsSep " " deps} -type f -name '*.nupkg' -exec \ - cp --no-clobber '{}' $out/lib ';' + ln -s '{}' -t $out/lib ';' # Generates a list of all licenses' spdx ids, if available. # Note that this currently ignores any license provided in plain text (e.g. "LICENSE.txt")