b5d57598b6f6c56d940b4ddfa42c617c0f5942de
Thanks to @Zertsov for #37932 which caused me to consider this implementation approach. One known issue with this is that it will not wait for actions that do async work to complete. Supporting this would require quite a lot of code change. It also doesn't affect the main usecase of sequencing editor actions, since few are async. Another caveat is that this is implemented as an action handler on workspace and so won't work in other types of windows. This seems fine for now, since action sequences don't seem useful in other window types. The command palette isn't accessible in non-workspace windows. Alternatives considered: * Add `cx: &App` to `Action::build`. This would allow removal of the special case in keymap parsing. Decided not to do this, since ideally `build` is a pure function of the input json. * Build it more directly into GPUI. The main advantage of this would be the potential to handle non-workspace windows. Since it's possible to do outside of GPUI, seems better to do so. While some aspects of the GPUI action system are pretty directly informed by the specifics of Zed's keymap files, it seems to avoid this as much as possible. * Bake it more directly into keymap syntax like in #37932. While I think it would be good for this to be a primitive in the JSON syntax, it seems like it would better fit in a more comprehensive change to provide better JSON structure. So in the meantime it seems better to keep the structure the same and just add a new action. - Another reason to not bake it in yet is that this provides a place to document the caveat about async actions. Closes #17710 Release Notes: - Added support for action sequences in keymaps. Example: `["action::Sequence", [ ["editor::SelectLargerSyntaxNode", "editor::Copy", "editor::UndoSelection"]` --------- Co-authored-by: Mitchel Vostrez <mitch@voz.dev>
Zed
Welcome to Zed, a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Installation
On macOS and Linux you can download Zed directly or install Zed via your local package manager.
Other platforms are not yet available:
- Windows (tracking issue)
- Web (tracking issue)
Developing Zed
- Building Zed for macOS
- Building Zed for Linux
- Building Zed for Windows
- Running Collaboration Locally
Contributing
See CONTRIBUTING.md for ways you can contribute to Zed.
Also... we're hiring! Check out our jobs page for open roles.
Licensing
License information for third party dependencies must be correctly provided for CI to pass.
We use cargo-about to automatically comply with open source licenses. If CI is failing, check the following:
- Is it showing a
no license specifiederror for a crate you've created? If so, addpublish = falseunder[package]in your crate's Cargo.toml. - Is the error
failed to satisfy license requirementsfor a dependency? If so, first determine what license the project has and whether this system is sufficient to comply with this license's requirements. If you're unsure, ask a lawyer. Once you've verified that this system is acceptable add the license's SPDX identifier to theacceptedarray inscript/licenses/zed-licenses.toml. - Is
cargo-aboutunable to find the license for a dependency? If so, add a clarification field at the end ofscript/licenses/zed-licenses.toml, as specified in the cargo-about book.
Description
GPUI – Community Edition maintained by Oak Team
https://gpui-ce.github.io/
258 MiB
Languages
Rust
95.6%
WGSL
1.2%
Metal
1.1%
HLSL
1.1%
Python
0.6%
Other
0.3%