We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2192631 commit c0f4eeaCopy full SHA for c0f4eea
README.md
@@ -205,6 +205,13 @@ server.enableExec(withDelegate: MyExecDelegate())
205
server.enableSFTP(withDelegate: MySFTPDelegate())
206
```
207
208
+If you're running the SSHServer from `main.swift` or an `@main` annotated type, make sure that Swift doesn't exit or `deinit` the server.
209
+A simple solution that is applicable most of the time is to use the server's `closeFuture`.
210
+
211
+```swift
212
+try await server.closeFuture.get()
213
+```
214
215
### Exec Server
216
217
When creating a command execution delegate, simply implement the `ExecDelegate` protocol and the following functions:
0 commit comments