Skip to content

Commit d9d5818

Browse files
committed
Add plugin description
1 parent d09622d commit d9d5818

3 files changed

Lines changed: 9 additions & 0 deletions

File tree

ChatPlugins/Sources/ShortcutChatPlugin/ShortcutChatPlugin.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ public final class ShortcutChatPlugin: ChatPlugin {
66
public static var id: String { "com.intii.shortcut" }
77
public static var command: String { "shortcut" }
88
public static var name: String { "Shortcut" }
9+
public static var description: String { """
10+
Run a shortcut and use message content as input. You need to provide the shortcut name as an argument, for example, `/shortcut(Shortcut Name)`.
11+
""" }
912

1013
let terminal: TerminalType
1114

ChatPlugins/Sources/TerminalChatPlugin/TerminalChatPlugin.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ public final class TerminalChatPlugin: ChatPlugin {
77
public static var id: String { "com.intii.terminal" }
88
public static var command: String { "run" }
99
public static var name: String { "Terminal" }
10+
public static var description: String { """
11+
Run the command in the message from terminal.
12+
13+
You can use environment variable `$FILE_PATH` and `$PROJECT_ROOT` to access the current file path and project root.
14+
""" }
1015

1116
let terminal: TerminalType
1217

Tool/Sources/ChatBasic/ChatPlugin.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ public protocol ChatPlugin {
1818
static var id: String { get }
1919
static var command: String { get }
2020
static var name: String { get }
21+
static var description: String { get }
2122
func send(_ request: Request) async -> AsyncThrowingStream<Response, any Error>
2223
func formatContent(_ content: Response.Content) -> Response.Content
2324
init()

0 commit comments

Comments
 (0)