diff --git a/pkgs/build-support/fetchgit/nix-prefetch-git b/pkgs/build-support/fetchgit/nix-prefetch-git index 2c9d61504ed..2af01ee5373 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 }