Expand description
The Zed Rust Extension API allows you write extensions for Zed in Rust.
Re-exports§
pub use serde_json;
Modules§
- http_
client - An HTTP client.
- lsp
- Constructs for interacting with language servers over the Language Server Protocol (LSP).
- process
- A module for working with processes.
- settings
- Provides access to Zed settings.
Macros§
- register_
extension - Registers the provided type as a Zed extension.
Structs§
- Attach
Request - Build
Task Definition Template Payload - Code
Label - A label containing some code.
- Code
Label Span Literal - A span containing a code literal.
- Context
Server Configuration - Configuration for context server setup and installation.
- Context
Server Id - The ID of a context server.
- Debug
Adapter Binary - The lowest-level representation of a debug session, which specifies:
- Debug
Config - Debug Config is the “highest-level” configuration for a debug session. It comes from a new session modal UI; thus, it is essentially debug-adapter-agnostic. It is expected of the extension to translate this generic configuration into something that can be debugged by the adapter (debug scenario).
- Debug
Scenario - Debug Scenario is the user-facing configuration type (used in debug.json). It is still concerned with what to debug and not necessarily how to do it (except for any debug-adapter-specific configuration options).
- Debug
Task Definition - Github
Release - A GitHub release.
- Github
Release Asset - An asset from a GitHub release.
- Github
Release Options - The options used to filter down GitHub releases.
- KeyValue
Store - A key-value store.
- Language
Server Id - The ID of a language server.
- Launch
Request - Project
- A Zed project.
- Slash
Command - A slash command for use in the Assistant.
- Slash
Command Argument Completion - A completion for a slash command argument.
- Slash
Command Output - The output of a slash command.
- Slash
Command Output Section - A section in the slash command output.
- Start
Debugging Request Arguments - Task
Template - TcpArguments
- TcpArguments
Template - Worktree
- A Zed worktree.
Enums§
- Architecture
- A platform architecture.
- Build
Task Definition - Code
Label Span - A span within a code label.
- Debug
Request - Downloaded
File Type - The type of a downloaded file.
- Language
Server Installation Status - The installation status for a language server.
- Os
- An operating system.
- Start
Debugging Request Arguments Request
Traits§
- Extension
- A Zed extension.
Functions§
- current_
platform - Gets the current operating system and architecture.
- download_
file - Downloads a file from the given URL and saves it to the given path within the extension’s working directory.
- github_
release_ by_ tag_ name - Returns the GitHub release with the specified tag name for the given GitHub repository.
- latest_
github_ release - Returns the latest release for the given GitHub repository.
- make_
file_ executable - Makes the file at the given path executable.
- node_
binary_ path - Returns the path to the Node binary used by Zed.
- npm_
install_ package - Installs the specified NPM package.
- npm_
package_ installed_ version - Returns the installed version of the given NPM package, if it exists.
- npm_
package_ latest_ version - Returns the latest version of the given NPM package.
- resolve_
tcp_ template - Resolves a specified TcpArgumentsTemplate into TcpArguments
- set_
language_ server_ installation_ status - Updates the installation status for the given language server.
Type Aliases§
- Build
Task Template - A task template for building a debug target.
- Command
- EnvVars
- Range
- Result
- A result returned from a Zed extension.