Skip to content

Commit 41f8ddc

Browse files
committed
Update default values of custom commands
1 parent 37689bd commit 41f8ddc

2 files changed

Lines changed: 16 additions & 1 deletion

File tree

Core/Sources/Preferences/Keys.swift

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,21 @@ public extension UserDefaultPreferenceKeys {
211211

212212
public extension UserDefaultPreferenceKeys {
213213
struct CustomCommandsKey: UserDefaultPreferenceKey {
214-
public let defaultValue: [CustomCommand] = []
214+
public let defaultValue: [CustomCommand] = [
215+
.init(
216+
name: "Explain Selection",
217+
feature: .chatWithSelection(
218+
prompt: "Explain the code concisely, do not interpret or translate it."
219+
)
220+
),
221+
.init(
222+
name: "Add Documentation to Selection",
223+
feature: .promptToCode(
224+
prompt: "Add documentation on top of the code.",
225+
continuousMode: false
226+
)
227+
)
228+
]
215229
public let key = "CustomCommands"
216230
}
217231

Core/Sources/Preferences/UserDefaults.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ public extension UserDefaults {
1010
shared.setupDefaultValue(for: \.automaticallyCheckForUpdate)
1111
shared.setupDefaultValue(for: \.suggestionPresentationMode)
1212
shared.setupDefaultValue(for: \.widgetColorScheme)
13+
shared.setupDefaultValue(for: \.customCommands)
1314
}
1415
}
1516

0 commit comments

Comments
 (0)