             let folder = try temporaryFolder.createSubfolderIfNeeded(withName: identifier)
             let fileName = scriptName(from: identifier) + ".swift"
             printer.reportProgress("Saving script...")
-            let file = try saveFile(from: url, destinationDirectory: folder, fileName: fileName)
+            let file = try saveFile(from: url, to: folder, fileName: fileName)
             temporaryScriptFiles.append(file)
 
             printer.reportProgress("Resolving \(config.dependencyFile)...")

    }

    @discardableResult
    private func saveFile(from url: URL, destinationDirectory: Folder, fileName: String) throws -> File {
        // Basically on Linux we can't use `Data(contentsOf:)` for getting the file
        // from a remote location. It just returns an empty data (on macOS works fine).
        // rdar://39621032
        #if os(Linux)
            let downloadCommand = "wget -O \"\(fileName)\" \"\(url.absoluteString)\""
            try destinationDirectory.moveToAndPerform(command: downloadCommand, printer: printer)
            return try destinationDirectory.file(named: fileName)
        #else
            let data = try Data(contentsOf: url)
            return try destinationDirectory.createFile(named: fileName, contents: data)
        #endif
    }


                let marathonFileURL = URL(string: parentURL.absoluteString + config.dependencyFile).require()

                printer.reportProgress("Saving \(config.dependencyFile)...")
                try saveFile(from: marathonFileURL, to: folder, fileName: config.dependencyFile)
            }

            return try script(from: file)
