From afa7e0187815d89c8af93fa9c1081bf67ab0f10e Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 1 Aug 2012 16:34:17 -0400 Subject: Inline unpack-channel.sh --- corepkgs/unpack-channel.nix | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) (limited to 'corepkgs/unpack-channel.nix') diff --git a/corepkgs/unpack-channel.nix b/corepkgs/unpack-channel.nix index 245430ab0feb..b26bece30eae 100644 --- a/corepkgs/unpack-channel.nix +++ b/corepkgs/unpack-channel.nix @@ -1,14 +1,27 @@ with import ; +let + + builder = builtins.toFile "unpack-channel.sh" + '' + mkdir $out + cd $out + ${bzip2} -d < $src | ${tar} xf - + mv * $out/$channelName + ''; + +in + { name, channelName, src }: derivation { system = builtins.currentSystem; builder = shell; - args = [ "-e" ./unpack-channel.sh ]; - inherit name channelName src bzip2 tar tr; + args = [ "-e" builder ]; + inherit name channelName src; + PATH = "${nixBinDir}:${coreutils}"; - + # No point in doing this remotely. preferLocalBuild = true; -- cgit 1.4.1