From efd963232712b5e54df0fd2be7c4c82404e30676 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A1rton=20Boros?= Date: Fri, 25 Mar 2022 13:03:07 +0200 Subject: [PATCH] support cabal.project source-repository-package commit --- lib/cabal-project-parser.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/cabal-project-parser.nix b/lib/cabal-project-parser.nix index 9f34c47caa..3793bb3fe6 100644 --- a/lib/cabal-project-parser.nix +++ b/lib/cabal-project-parser.nix @@ -76,7 +76,7 @@ let # (used in call-cabal-project-to-nix.nix to create a fixed-output derivation) extractSourceRepoPackageData = cabalProjectFileName: sha256map: repo: { url = repo.location; - ref = repo.tag; + ref = if repo ? commit then repo.commit else repo.tag; sha256 = repo."--sha256" or ( if sha256map != null then sha256map."${repo.location}"."${repo.tag}"