From 9bb6c537f4aed7cdc4f4d7373b67e4cdb2fb3f17 Mon Sep 17 00:00:00 2001 From: George Barnett Date: Mon, 7 Oct 2024 17:02:17 +0100 Subject: [PATCH] Ensure file path isn't percent encoded in the plugin Motivation: In Swift 6, SwiftPM deprecated its Path based API for plugins and moved to Foundation's URL. On Darwin, getting the path of a URL percent encodes it which leads to build issues in Xcode. Modifications: - Make sure the path isn't percent encoded Result: - Plugin works again - Resolves #2085 --- Plugins/GRPCSwiftPlugin/plugin.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Plugins/GRPCSwiftPlugin/plugin.swift b/Plugins/GRPCSwiftPlugin/plugin.swift index 107b3f787..2c773e79c 100644 --- a/Plugins/GRPCSwiftPlugin/plugin.swift +++ b/Plugins/GRPCSwiftPlugin/plugin.swift @@ -319,7 +319,7 @@ struct PathLike: CustomStringConvertible { #if compiler(<6.0) return String(describing: self.value) #elseif canImport(Darwin) - return self.value.path() + return self.value.path(percentEncoded: false) #else return self.value.path #endif