From d0b5f89fcfd7fec771e086e7e768e9c6b370fde9 Mon Sep 17 00:00:00 2001 From: Markus Chmelar Date: Mon, 13 Nov 2017 18:21:33 +0100 Subject: [PATCH] Strip string terminator from result of git command --- Source/CarthageKit/Git.swift | 1 + 1 file changed, 1 insertion(+) diff --git a/Source/CarthageKit/Git.swift b/Source/CarthageKit/Git.swift index 17c2d09f52..41cb0132bf 100644 --- a/Source/CarthageKit/Git.swift +++ b/Source/CarthageKit/Git.swift @@ -336,6 +336,7 @@ internal func gitmodulesEntriesInRepository( .flatMap(.concat) { value in parseConfigEntries(value, keyPrefix: "submodule.", keySuffix: ".path") } .flatMap(.concat) { name, path -> SignalProducer<(name: String, path: String, url: GitURL), CarthageError> in return launchGitTask(baseArguments + [ "--get", "submodule.\(name).url" ], repositoryFileURL: repositoryFileURL) + .map { $0.stripping(suffix: "\0") } .map { urlString in (name: name, path: path, url: GitURL(urlString)) } } }