Skip to content

Commit 4915076

Browse files
authored
Fix HelloWorld Samples (#1505)
* Fixed HelloWorld samples - Samples were not starting up without a main function * Fixed code review comments
1 parent cfa950f commit 4915076

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

Sources/Examples/HelloWorld/Client/main.swift renamed to Sources/Examples/HelloWorld/Client/helloworldclient.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ import HelloWorldModel
2020
import NIOCore
2121
import NIOPosix
2222

23+
@main
2324
@available(macOS 10.15, iOS 13, tvOS 13, watchOS 6, *)
2425
struct HelloWorld: AsyncParsableCommand {
2526
@Option(help: "The port to connect to")

Sources/Examples/HelloWorld/Server/main.swift renamed to Sources/Examples/HelloWorld/Server/HelloWorldServer.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ import HelloWorldModel
2020
import NIOCore
2121
import NIOPosix
2222

23+
@main
2324
@available(macOS 10.15, iOS 13, tvOS 13, watchOS 6, *)
2425
struct HelloWorld: AsyncParsableCommand {
2526
@Option(help: "The port to listen on for new connections")

0 commit comments

Comments
 (0)