extension: Make worktree
argument to run_slash_command
optional (#15658)
This PR updates the extension API to make the `worktree` argument to `run_slash_command` optional. We may not always have a worktree, and not all slash commands need them, so by making it optional we can allow individual slash commands to decide what to do when there is no worktree. Release Notes: - N/A
This commit is contained in:
parent
88f29c8355
commit
771424e4f9
5 changed files with 12 additions and 9 deletions
|
@ -133,7 +133,7 @@ world extension {
|
|||
export complete-slash-command-argument: func(command: slash-command, query: string) -> result<list<slash-command-argument-completion>, string>;
|
||||
|
||||
/// Returns the output from running the provided slash command.
|
||||
export run-slash-command: func(command: slash-command, argument: option<string>, worktree: borrow<worktree>) -> result<slash-command-output, string>;
|
||||
export run-slash-command: func(command: slash-command, argument: option<string>, worktree: option<borrow<worktree>>) -> result<slash-command-output, string>;
|
||||
|
||||
/// Indexes the docs for the specified package.
|
||||
export index-docs: func(provider-name: string, package-name: string, database: borrow<key-value-store>) -> result<_, string>;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue