summary refs log tree commit diff
diff options
context:
space:
mode:
-rwxr-xr-xpkgs/build-support/fetchgit/nix-prefetch-git7
1 files changed, 6 insertions, 1 deletions
diff --git a/pkgs/build-support/fetchgit/nix-prefetch-git b/pkgs/build-support/fetchgit/nix-prefetch-git
index 2c9d61504ed25..2af01ee5373bf 100755
--- a/pkgs/build-support/fetchgit/nix-prefetch-git
+++ b/pkgs/build-support/fetchgit/nix-prefetch-git
@@ -327,7 +327,12 @@ print_results() {
         echo "{"
         echo "  \"url\": \"$url\","
         echo "  \"rev\": \"$fullRev\","
-        echo "  \"$hashType\": \"$hash\""
+        echo -n "  \"$hashType\": \"$hash\""
+        if test -n "$fetchSubmodules"; then
+            echo ","
+            echo -n "  \"fetchSubmodules\": true"
+        fi
+        echo ""
         echo "}"
     fi
 }