From 70ae89b91c08a5af7bb27792de8c0b0304124bd7 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Thu, 18 Apr 2019 15:14:23 +0800 Subject: [PATCH] sinara-systems: fix git hash computation --- sinara-systems.nix | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/sinara-systems.nix b/sinara-systems.nix index 826d854..7814d37 100644 --- a/sinara-systems.nix +++ b/sinara-systems.nix @@ -7,7 +7,12 @@ let '' mkdir $out REV=`git --git-dir ${sinaraSystemsSrc}/.git rev-parse HEAD` - HASH=`nix-hash --type sha256 --base32 ${sinaraSystemsSrc}` + SINARA_SRC_CLEAN=`mktemp -d` + cp -a ${sinaraSystemsSrc}/. $SINARA_SRC_CLEAN + chmod -R 755 $SINARA_SRC_CLEAN/.git + chmod 755 $SINARA_SRC_CLEAN + rm -rf $SINARA_SRC_CLEAN/.git + HASH=`nix-hash --type sha256 --base32 $SINARA_SRC_CLEAN` cat > $out/default.nix << EOF { pkgs ? import {}}: @@ -22,7 +27,6 @@ let url = "git://github.com/m-labs/sinara-systems.git"; rev = "$REV"; sha256 = "$HASH"; - leaveDotGit = true; }; generic-kasli = pkgs.lib.lists.foldr (variant: start: let