File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change 27
27
28
28
extension Plugin {
29
29
30
- public static func main( ) throws {
30
+ public static func main( ) async throws {
31
31
// Look for the input JSON as the last argument of the invocation.
32
32
guard let inputData = ProcessInfo . processInfo. arguments. last? . data ( using: . utf8) else {
33
33
fputs ( " Expected last argument to contain JSON input data in UTF-8 encoding, but didn't find it. " , stderr)
@@ -57,7 +57,7 @@ extension Plugin {
57
57
guard let plugin = plugin as? BuildToolPlugin else {
58
58
throw PluginDeserializationError . malformedInputJSON ( " Plugin declared with `buildTool` capability but doesn't conform to `BuildToolPlugin` protocol " )
59
59
}
60
- let commands = try plugin. createBuildCommands ( context: context)
60
+ let commands = try await plugin. createBuildCommands ( context: context)
61
61
62
62
// Convert the commands to the encodable output representation SwiftPM currently expects.
63
63
output. buildCommands = commands. compactMap {
Original file line number Diff line number Diff line change @@ -31,5 +31,5 @@ public protocol BuildToolPlugin: Plugin {
31
31
/// commands, configured based on the information in the context.
32
32
func createBuildCommands(
33
33
context: TargetBuildContext
34
- ) throws -> [ Command ]
34
+ ) async throws -> [ Command ]
35
35
}
You can’t perform that action at this time.
0 commit comments