diff --git a/Sources/XcodeGenKit/FileWriter.swift b/Sources/XcodeGenKit/FileWriter.swift index 2ce3c415..7c6a1160 100644 --- a/Sources/XcodeGenKit/FileWriter.swift +++ b/Sources/XcodeGenKit/FileWriter.swift @@ -12,7 +12,7 @@ public class FileWriter { } public func writeXcodeProject(_ xcodeProject: XcodeProj, to projectPath: Path? = nil) throws { - let projectPath = project.defaultProjectPath + let projectPath = projectPath ?? project.defaultProjectPath let tempPath = try Path.processUniqueTemporary() + "XcodeGen" try? tempPath.delete() if projectPath.exists {