This PR implements the Centered Layout feature (#4685):
- Added the `toggle centered layout` action.
- The centered layout mode only takes effect when there's a single
central pane.
- The state of the centered layout toggle is saved / restored between
Zed restarts.
- The paddings are controlled by the `centered_layout` setting:
```json
"centered_layout": {
"left_padding": 0.2,
"right_padding": 0.2
}
```
This allows us to support both the VSCode-style (equal paddings) and
IntelliJ-style (only left padding in Zen mode).
Release Notes:
- Added support for Centered Layout
([#4685](https://github.com/zed-industries/zed/pull/9754)).
https://github.com/zed-industries/zed/assets/2101250/2d5b2a16-c248-48b5-9e8c-6f1219619398
Related Issues:
- Part of #4382
Add some keywords (bracket, quote, etc)to the comments describing
`use_autoclose` preference in the settings json.
This setting took me a while to find -- so now it'll be more easily
searchable for others.
Release Notes:
- N/A
Release Notes:
- Added a setting to show/hide the terminal button in the status bar:
`{"terminal": {"button": false}}` to hide it. (#10513)
---------
Co-authored-by: Thorsten Ball <mrnugget@gmail.com>
Zed displays scrollbar markers of three types: git diffs, background
highlights and diagnostics. At the moment, the "background highlights"
markers are displayed for all the supported highlights:
- Occurences of the symbol under cursor.
- Search results.
- Scope boundaries (only works when a symbol is selected).
- Active hover popover position.
They all use the same color, which leads to confusing results. For
instance, in the following case I expect to see markers for the
`new_anchor` occurences in lines 43 and 47. But besides them, there're
also scope-markers for `ScrollAnchor` initialization block in lines 46
and 49, which makes me think that there're four places where
`new_anchor` appears.
<img width="740" alt="zed-scrollbar-markers"
src="https://github.com/zed-industries/zed/assets/2101250/78700e6b-fdd1-4c2f-beff-e564d8defc13">
Existing settings `selection` and `symbol_selection` in the `scrollbar`
section [don't work as
expected](https://github.com/zed-industries/zed/pull/10080#discussion_r1552325493),
which increases confusion.
This PR only leaves two types of bg-highlight-markers and provides
dedicated settings for them:
- Occurences of the symbol under cursor. Setting: `selected_symbol`,
default is `true`.
- Search results. Setting: `search_results`, default is `true`.
The `selection` and `symbol_selection` settings are not used anymore.
Release Notes:
- Breaking changes. Settings `selection` and `symbol_selection` in the
`scrollbar` section renamed to `search_results` and `selected_symbol`
respectively. Fixed the effect of these settings on which markers are
displayed on the scrollbar.
Optionally, include screenshots / media showcasing your addition that
can be included in the release notes.
- N/A
/cc @mrnugget
Some people (like myself) use touchpads for development and I find Zed's
default scroll sensitivity to be slower than I like. This change adds a
scroll sensitivity multiplier that allows users to customize the speed
of their scrolling.
Release Notes:
- Added a setting under "scroll_sensitivity" that allows user to control
the scroll sensitivity. This value acts as a multiplier for the
horizontal and vertical scroll speed.
This adds so-called "inline git blame" to the editor that, when turned
on, shows `git blame` information about the current line inline:
![screenshot-2024-04-15-11 29
35@2x](https://github.com/zed-industries/zed/assets/1185253/21cef7be-3283-4556-a9f0-cc349c4e1d75)
When the inline information is hovered, a new tooltip appears that
contains more information on the current commit:
![screenshot-2024-04-15-11 28
24@2x](https://github.com/zed-industries/zed/assets/1185253/ee128460-f6a2-48c2-a70d-e03ff90a737f)
The commit message in this tooltip is rendered as Markdown, is
scrollable and clickable.
The tooltip is now also the tooltip used in the gutter:
![screenshot-2024-04-15-11 28
51@2x](https://github.com/zed-industries/zed/assets/1185253/42be3d63-91d0-4936-8183-570e024beabe)
## Settings
1. The inline git blame information can be turned on and off via
settings:
```json
{
"git": {
"inline_blame": {
"enabled": true
}
}
}
```
2. Optionally, a delay can be configured. When a delay is set, the
inline blame information will only show up `x milliseconds` after a
cursor movement:
```json
{
"git": {
"inline_blame": {
"enabled": true,
"delay_ms": 600
}
}
}
```
3. It can also be turned on/off for the current buffer with `editor:
toggle git blame inline`.
## To be done in follow-up PRs
- [ ] Add link to pull request in tooltip
- [ ] Add avatars of users if possible
## Release notes
Release Notes:
- Added inline `git blame` information the editor. It can be turned on
in the settings with `{"git": { "inline_blame": "on" } }` for every
buffer or, temporarily for the current buffer, with `editor: toggle git
blame inline`.
Fixed auto folded dirs which caused significant performance issues #8476
(#7674)
Moved from iterating over snapshot entries to use `child_entries`
function from `worktree.rs` by making it public
@maxbrunsfeld
Release Notes:
- Fixed a bug where project panel settings changes would not be applied
immediately.
- Added a `project_panel.auto_fold_dirs` setting which collapses the
nesting in the project panel when there is a chain of folders containing
a single folder.
<img width="288" alt="Screenshot 2024-04-12 at 11 10 58 AM"
src="https://github.com/zed-industries/zed/assets/2280405/efd61e75-026c-464d-ba4d-90db5f68bad3">
---------
Co-authored-by: Mikayla <mikayla@zed.dev>
This implements some of #10457.
Release notes:
- Added `g c c` and `g c` to Vim keybindings to toggle comments in
normal and visual mode respectively.
- Added `g ]` and `g [` to Vim keybindings to go to next and previous
diagnostic error.
- Changed `[ x` and `] x` (which select larger/smaller syntax node) in
Vim mode to also work in visual mode.
This PR implements the preview tabs feature from VSCode.
More details and thanks for the head start of the implementation here
#6782.
Here is what I have observed from using the vscode implementation ([x]
-> already implemented):
- [x] Single click on project file opens tab as preview
- [x] Double click on item in project panel opens tab as permanent
- [x] Double click on the tab makes it permanent
- [x] Navigating away from the tab makes the tab permanent and the new
tab is shown as preview (e.g. GoToReference)
- [x] Existing preview tab is reused when opening a new tab
- [x] Dragging tab to the same/another panel makes the tab permanent
- [x] Opening a tab from the file finder makes the tab permanent
- [x] Editing a preview tab will make the tab permanent
- [x] Using the space key in the project panel opens the tab as preview
- [x] Handle navigation history correctly (restore a preview tab as
preview as well)
- [x] Restore preview tabs after restarting
- [x] Support opening files from file finder in preview mode (vscode:
"Enable Preview From Quick Open")
I need to do some more testing of the vscode implementation, there might
be other behaviors/workflows which im not aware of that open an item as
preview/make them permanent.
Showcase:
https://github.com/zed-industries/zed/assets/53836821/9be16515-c740-4905-bea1-88871112ef86
TODOs
- [x] Provide `enable_preview_tabs` setting
- [x] Write some tests
- [x] How should we handle this in collaboration mode (have not tested
the behavior so far)
- [x] Keyboard driven usage (probably need workspace commands)
- [x] Register `TogglePreviewTab` only when setting enabled?
- [x] Render preview tabs in tab switcher as italic
- [x] Render preview tabs in image viewer as italic
- [x] Should this be enabled by default (it is the default behavior in
VSCode)?
- [x] Docs
Future improvements (out of scope for now):
- Support preview mode for find all references and possibly other
multibuffers (VSCode: "Enable Preview From Code Navigation")
Release Notes:
- Added preview tabs
([#4922](https://github.com/zed-industries/zed/issues/4922)).
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
As of #10393 some icons in the chat were invisible, looking at the icons
I noticed that the viewport was actually 800x800, I scaled that down to
16x16 and now they work fine again.
Also remove the `reply_arrow_left` icon because it is not used at all.
Thanks to @RemcoSmitsDev for noticing.
I don't have any expertise in svg's, so if something is off about the
svg markup reach out to me.
Release Notes:
- N/A
Fixes#7694
The new setting accepts "last_workspace" (default) and "none" as
options.
In a follow-up PR I'll add a new option that re-launches all of the Zed
windows and not just the last one.
Release Notes:
- Added `restore_on_startup` option, accepting `last_workspace`
(default) and `none` options. With `none`, new Zed instances will not
restore workspaces that were open last.
In addition to `ctrl-tab` and `ctrl-shift-tab`, VS Code allows changing
the selection in the tab switcher via the up and down arrow keys.
Release Notes:
- Added bindings to allow `up` and `down` arrow keys to be used while
the tab switcher is open.
Followup to #10327
It can be enabled with the following setting:
"line_indicator_format": "short"
No release note, as the original change didn't go out to Preview yet.
/cc @bartekpacia @0x2CA
Release Notes:
- N/A
To reference the system font, use the special ".SystemUIFont" family
name.
/cc @PixelJanitor
Release Notes:
- Switched to the system UI font for user interface elements on macOS.
Co-authored-by: Antonio Scandurra <antonio@zed.dev>
This PR changes ways the Find/Replace functionality in the
Buffer/Project Search is accessible via shortcuts. It makes those panels
work the same way as in VS Code and Sublime Text.
The details are described in the issue: [Make Find/Replace easier to
use](https://github.com/zed-industries/zed/issues/9142)
There's a difficulty with the Linux keybindings:
VS Code uses on MacOS (this PR replicates it):
| Action | Buffer Search | Project Search |
| --- | --- | --- |
| Find | `cmd-f` | `cmd-shift-f` |
| Replace | `cmd-alt-f` | `cmd-shift-h` |
VS Code uses on Linux (this PR replicates all but one):
| Action | Buffer Search | Project Search |
| --- | --- | --- |
| Find | `ctrl-f` | `ctrl-shift-f` |
| Replace | `ctrl-h` ❗ | `ctrl-shift-h` |
The problem is that `ctrl-h` is already taken by the `editor::Backspace`
action in Zed on Linux.
There's two options here:
1. Change keybinding for `editor::Backspace` on Linux to something else,
and use `ctrl-h` for the "replace in buffer" action.
2. Use some other keybinding on Linux in Zed. This PR introduces
`ctrl-r` for this purpose, though I'm not sure it's the best choice.
What do you think?
fixes#9142
Release Notes:
- Improved access to "Find/Replace in Buffer" and "Find/Replace in
Files" via shortcuts (#9142).
Optionally, include screenshots / media showcasing your addition that
can be included in the release notes.
- N/A
This PR adds the ability for extensions to provide certain language
settings via the language `config.toml`.
These settings are then merged in with the rest of the settings when the
language is loaded from the extension.
The language settings that are available are:
- `tab_size`
- `hard_tabs`
- `soft_wrap`
Additionally, for bundled languages we moved these settings out of the
`settings/default.json` and into their respective `config.toml`s .
For languages currently provided by extensions, we are leaving the
values in the `settings/default.json` temporarily until all released
versions of Zed are able to load these settings from the extension.
---
Along the way we ended up refactoring the `Settings::load` method
slightly, introducing a new `SettingsSources` struct to better convey
where the settings are being loaded from.
This makes it easier to load settings from specific locations/sets of
locations in an explicit way.
Release Notes:
- N/A
---------
Co-authored-by: Max <max@zed.dev>
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
For #4965
There are still some minor issues:
1. When change the surround and delete the surround, we should also
decide whether there are spaces inside after deleting/replacing
according to whether it is open parentheses, and replace them
accordingly, but at present, delete and change, haven't done this
adaptation for current pr, I'm not sure if I can fit it in the back or
if it needs to be fitted together.
2. In the selection mode, pressing s plus brackets should also trigger
the Add Surrounds function, but this MR has not adapted the selection
mode for the time being, I think we need to support different add
behaviors for the three selection modes.(Currently in select mode, s is
used for Substitute)
3. For the current change surrounds, if the user does not find the
bracket that needs to be matched after entering cs, but it is a valid
bracket, and will wait for the second input before failing, the better
practice here should be to return to normal mode if the first bracket is
not found
4. I reused BracketPair in language, but two of its properties weren't
used in this mr, so I'm not sure if I should create a new struct with
only start and end, which would have less code
I'm not sure which ones need to be changed in the first issue, and which
ones can be revised in the future, and it seems that they can be solved
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
We want Zed to be opinionated and low-configuration. Your code editor
should get out of the way, and just do the right thing.
However, some ecosystems aren't opinionated enough for us to
automatically detect the right way to format your code, so let's turn it
off.
Release Notes:
- Disabled `format_on_save` by default in C and C++.
Release Notes:
- Resolves#4273
@algora-pbc /claim #4273
This is a work-in-progress. The process for `gn` command is:
- maintain updated vim.workspace_state.search.initial_query
- modify editor.select_next_state with
vim.workspace_state.search.initial_query
- use editor.select_next()
- merge selections
- set editor.select_next_state to previous state
To make this possible, several private members and editor structures are
made public. `gN` is not yet implemented and the cursor still does not
jump to the next selection in the first use.
Maybe there is an better way to do this?
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
If you use soft tabs by default, editing Makefiles will be broken as
they require tab indentation to parse correctly.
Release Notes;
- Changed default settings for `Makefile`s to use hard tabs.
This PR updates the color of the label used for Git-aware items to use
the `ignored` color from the theme when the item is ignored by Git.
The built-in themes have had their `ignored` color updated to match
`text.disabled`, as the existing `ignored` color did not sufficiently
differentiate from non-ignored items.
Fixes#9976.
Release Notes:
- Updated items in the project panel to use the `ignored` color from the
theme when they are ignored by Git
([#9976](https://github.com/zed-industries/zed/issues/9976)).
These tasks are not considered for reruns with `task::Rerun`.
This PR tears a bunch of stuff up around tasks:
- `menu::SecondaryConfirm` for tasks is gonna spawn a task without
storing it in history instead of being occupied by oneshot tasks. This
is done so that cmd-clicking on the menu item actually does something
meaningful.
- `menu::UseSelectedQuery` got moved into picker, as tasks are it's only
user (and it doesn't really make sense as a menu action).
TODO:
- [x] add release note
- [x] Actually implement the core of this feature, which is spawning a
task without saving it in history, lol.
Fixes#9804
Release Notes:
- Added "fire-and-forget" task spawning; `menu::SecondaryConfirm` in
tasks modal now spawns a task without registering it as the last spawned
task for the purposes of `task::Rerun`. By default you can spawn a task
in this fashion with cmd+enter or by holding cmd and clicking on a task
entry in a list. Spawning oneshots has been rebound to `option-enter`
(under a `picker::ConfirmInput` name). Fixes#9804 (breaking change)
- Moved `menu::UseSelectedQuery` action to `picker` namespace (breaking
change).
The Tab Switcher implementation (#7653):
- `ctrl-tab` opens the Tab Switcher and moves selection to the
previously selcted tab. It also cycles selection forward.
- `ctrl-shift-tab` opens the Tab Switcher and moves selection to the
last tab in the list. It also cycles selection backward.
- Tab is selected and the Tab Switcher is closed on the shortcut
modifier key (`ctrl` by default) release.
- List items are in reverse activation history order.
- The list reacts to the item changes in background (new tab, tab
closed, tab title changed etc.)
Intentionally not in scope of this PR:
- File icons
- Close buttons
I will come back to these features. I think they need to be implemented
in separate PRs, and be synchronized with changes in how tabs are
rendered, to reuse the code as it's done in the current implementation.
The Tab Switcher looks usable even without them.
Known Issues:
Tab Switcher doesn't react to mouse click on a list item. It's not a tab
switcher specific problem, it looks like ctrl-clicks are not handled the
same way in Zed as cmd-clicks. For instance, menu items can be activated
with cmd-click, but don't react to ctrl-click. Since the Tab Switcher's
default keybinding is `ctrl-tab`, the user can only click an item with
`ctrl` pushed down, thus preventing `on_click()` from firing.
fixes#7653, #7321
Release Notes:
- Added Tab Switcher which is accessible via `ctrl-tab` and
`ctrl-shift-tab` (#7653) (#7321)
Related issues:
- Unblocks #7356, I hope 😄
How it looks and works (it's only `ctrl-tab`'s and `ctrl-shift-tab`'s,
no `enter`'s or mouse clicks):
https://github.com/zed-industries/zed/assets/2101250/4ad4ec6a-5314-481b-8b35-7ac85e43eb92
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Co-authored-by: Mikayla Maki <mikayla@zed.dev>
This adds a keybinding for an existing action. Notably, our bindings for
`Go To Type Definition` and `Go To Implementation` are swapped from
VSCode. We use `cmd` and `shift`, they use `shift` and `cmd`.
Release Notes:
- Added a keybinding for `editor::GoToImplementation`
Earlier versions where a simple find-replace of `cmd` => `ctrl`. In this
PR, I've gone over every keybinding individually and checked them.
Release Notes:
- Removed the `ShowContextMenu` action, it's only usage was in the
collab panel and it's been rebound to `SecondaryConfirm`
This pull request introduces a new `InlineCompletionProvider` trait,
which enables making `Editor` copilot-agnostic and lets us push all the
copilot functionality into the `copilot_ui` module. Long-term, I would
like to merge `copilot` and `copilot_ui`, but right now `project`
depends on `copilot`, which makes this impossible.
The reason for adding this new trait is so that we can experiment with
other inline completion providers and swap them at runtime using config
settings.
Please, note also that we renamed some of the existing copilot actions
to be more agnostic (see release notes below). We still kept the old
actions bound for backwards-compatibility, but we should probably remove
them at some later version.
Also, as a drive-by, we added new methods to the `Global` trait that let
you read or mutate a global directly, e.g.:
```rs
MyGlobal::update(cx, |global, cx| {
});
```
Release Notes:
- Renamed the `copilot::Suggest` action to
`editor::ShowInlineCompletion`
- Renamed the `copilot::NextSuggestion` action to
`editor::NextInlineCompletion`
- Renamed the `copilot::PreviousSuggestion` action to
`editor::PreviousInlineCompletion`
- Renamed the `editor::AcceptPartialCopilotSuggestion` action to
`editor::AcceptPartialInlineCompletion`
---------
Co-authored-by: Nathan <nathan@zed.dev>
Co-authored-by: Kyle <kylek@zed.dev>
Co-authored-by: Kyle Kelley <rgbkrk@gmail.com>
This PR adds a new `assistant.enabled` setting that controls whether the
Zed Assistant is enabled.
Some users have requested the ability to disable the AI-related features
in Zed if they don't use them. Changing `assistant.enabled` to `false`
will hide the Assistant icon in the status bar (taking priority over the
`assistant.button` setting) as well as filter out the `assistant:`
actions.
The Assistant is enabled by default.
Release Notes:
- Added an `assistant.enabled` setting to control whether the Assistant
is enabled.
`alt+left/right` are never used on Linux.
The Linux keymap still has some other issues, but these shortcuts in
particular are really common when editing text.
Release Notes:
- N/A
This PR adds support for handling action releases — events that
are fired when the user releases all the modifier keys that were part of
an action-triggering shortcut.
If the user holds modifiers and invokes several actions sequentially via
shortcuts (same or different), only the last action is "released" when
its modifier keys released.
~The following methods were added to `Div`:~
- ~`capture_action_release()`~
- ~`on_action_release()`~
- ~`on_boxed_action_release()`~
~They work similarly to `capture_action()`, `on_action()` and
`on_boxed_action()`.~
See the implementation details in [this
comment](https://github.com/zed-industries/zed/pull/8782#issuecomment-2009154646).
Release Notes:
- Added a fast-switch mode to the file finder: hit `p` or `shift-p`
while holding down `cmd` to select a file immediately. (#8258).
Related Issues:
- Implements #8757
- Implements #8258
- Part of #7653
Co-authored-by: @ConradIrwin
**Summary**:
- Removed reply message from message_menu
- Made render_popover_buttons a bit more reusable
- Fixed issue that you can't close the reply/edit preview when you are
not focusing the message editor
- Notify only the new people that were mentioned inside the edited
message
**Follow up**
- Fix that we update the notification message for the people that we
mentioned already
- Fix that we remove the notification when a message gets deleted.
- Fix last acknowledge message id is in correct now
**Todo**:
- [x] Add tests
- [x] Change new added bindings to the `Editor::Cancel` event.
Release Notes:
- Added editing of chat messages
([#6707](https://github.com/zed-industries/zed/issues/6707)).
<img width="239" alt="Screenshot 2024-03-09 at 11 55 23"
src="https://github.com/zed-industries/zed/assets/62463826/b0949f0d-0f8b-43e1-ac20-4c6d40ac41e1">
<img width="240" alt="Screenshot 2024-03-13 at 13 34 23"
src="https://github.com/zed-industries/zed/assets/62463826/d0636da2-c5aa-4fed-858e-4bebe5695ba7">
---------
Co-authored-by: Bennet Bo Fenner <53836821+bennetbo@users.noreply.github.com>
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Co-authored-by: Antonio <antonio@zed.dev>
Resurrected this from some assistant work I did in Spring of 2023.
- [x] Resurrect streaming responses
- [x] Use streaming responses to enable AI via Zed's servers by default
(but preserve API key option for now)
- [x] Simplify protobuf
- [x] Proxy to OpenAI on zed.dev
- [x] Proxy to Gemini on zed.dev
- [x] Improve UX for switching between openAI and google models
- We current disallow cycling when setting a custom model, but we need a
better solution to keep OpenAI models available while testing the google
ones
- [x] Show remaining tokens correctly for Google models
- [x] Remove semantic index
- [x] Delete `ai` crate
- [x] Cloud front so we can ban abuse
- [x] Rate-limiting
- [x] Fix panic when using inline assistant
- [x] Double check the upgraded `AssistantSettings` are
backwards-compatible
- [x] Add hosted LLM interaction behind a `language-models` feature
flag.
Release Notes:
- We are temporarily removing the semantic index in order to redesign it
from scratch.
---------
Co-authored-by: Antonio <antonio@zed.dev>
Co-authored-by: Antonio Scandurra <me@as-cii.com>
Co-authored-by: Thorsten <thorsten@zed.dev>
Co-authored-by: Max <max@zed.dev>
Completes #7228.
Adds back Backspace as the main delete key binding and makes Linux
bindings consistent with macOS
Release Notes:
- ⌘-Delete/⌘-Backspace will now suppress deletion confirmation prompts
in project panel
([#7228](https://github.com/zed-industries/zed/issues/7228)).
This is an update to 82 Zed UI and file_icons to improve icon legibility
and align contributed file_icons to the general icon system styling.
From review it appears they're 2px larger in width and height but gpui
render scaling is at play. The original icons were designed at 14x14 to
be viewed at that size, but the ui_font_size now controls this so
they've been updated to the default of 16x16 for optimum fidelity.
![CleanShot 2024-03-17 at 16 20
13@2x](https://github.com/zed-industries/zed/assets/1648941/4151c631-78e6-43a8-914f-37b00f43e130)
Release Notes:
- Updated various UI and file icons for consistency.
* Add a `reveal: always|never` field in task definitions from tasks.json
, allowing to customize task terminal behavior on spawn
* Ensure reveal: always reveals the terminal even if the old task is
already running
Release Notes:
- Added a `reveal: always|never` (`always` is a default) field in task
definitions from tasks.json , allowing to customize task terminal
behavior on spawn
---------
Co-authored-by: Piotr Osiewicz <piotr@zed.dev>
Hello! This PR proposes a redesigned replying system in Zeds chat panel,
inspired by chat applications like [Slack](https://slack.com) and
[Discord](https://discord.com). Feedback and suggestions are welcome! 😄
### TODOs
- [x] Handle replies to removed messages
- [x] Add replied user's profile picture to reply indicator
- [x] Highlight the message that's been selected for replying
--------
### Current Status
https://github.com/zed-industries/zed/assets/146845123/4ed2c2d7-a586-48bd-973c-0d3f033e2c6b
--------
Release Notes:
- Redesigned message replies in the chat panel
---------
Co-authored-by: Thorsten Ball <mrnugget@gmail.com>
this PR allows users to use `cmd` instead of `alt` as the
`multi_cursor_modifier` for creating multiple cursors/selections
closes#4339
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
For #4440, I've only added support for normal, if it's visual mode,
would we like this to delete the current selection row and enter insert
mode?
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
The important change here is to ensure that undo never lands you in
visual mode; but we also take care to restore the selection the same way
vim does (visual line goes to beginning of line, visual block to the top
left, etc.).
To help make this behaviour feel right we also group any deletions that
started insert mode with the first text inserted.
Fixes: #7521
Release Notes:
- vim: Improved undo. It will now restore you to normal mode in the same
position as vim, and group deletions caused by `c` or `s` with the
concomitant insert.
([#7521](https://github.com/zed-industries/zed/issues/7521)).
Closes#5178
Release Notes:
- Added a `file_types` setting that can be used to associate languages
with file names and file extensions. For example, to interpret all `.c`
files as C++, and files called `MyLockFile` as TOML, add the following
to `settings.json`:
```json
{
"file_types": {
"C++": ["c"],
"TOML": ["MyLockFile"]
}
}
```
As with most zed settings, this can be configured on a per-directory
basis by including a local `.zed/settings.json` file in that directory.
---------
Co-authored-by: Marshall <marshall@zed.dev>
This PR fixes some typos in the comments within the default
`settings.json` file.
Fixes#4257.
Release Notes:
- Fixed some incorrect comments in the default `settings.json` file
([#4257](https://github.com/zed-industries/zed/issues/4257)).
Closes https://github.com/zed-industries/zed/issues/5275
Double click with `alt` modifier pressed will do the regular word
selection.
Adds a setting to disable this behavior and instead select a word, as in
the regular buffer.
```
// What to do when multibuffer is double clicked in some of its excerpts
// (parts of singleton buffers).
// May take 2 values:
// 1. Behave as a regular buffer and select the whole word.
// "double_click_in_multibuffer": "select"
// 2. Open the excerpt clicked as a new buffer in the new tab (default).
// "double_click_in_multibuffer": "open",
// For the case of "open", regular selection behavior can be achieved by holding `alt` when double clicking.
"double_click_in_multibuffer": "open",
```
Release Notes:
- Made multibuffer to open excerpts in new tabs on double click by
default (changing settings or keeping alt restores the word selection
behavior). ([5275](https://github.com/zed-industries/zed/issues/5275))
`[x` will select the larger syntax node, `]x` the smaller one. Inspired
by https://github.com/tpope/vim-unimpaired.
Release Notes:
- Added `[x` and `]x` as default keybindings in Vim mode to select
larger and smaller syntax nodes respectively.
Release Notes:
- Changed default keybindings in the VS Code keymap so that
`alt-[up|down]` now move lines up/down and`alt-shift-[up|down]`
duplicate lines up/down. Previous bindings for selecting larger/smaller
syntax nodes are now bound to `ctrl-shift-[left|right]`.
([#4652](https://github.com/zed-industries/zed/issues/4652))([#7151](https://github.com/zed-industries/zed/issues/7151))
---------
Co-authored-by: Thorsten Ball <mrnugget@gmail.com>
This PR adds support for `ap`/`ip` text objects in Vim mode and allows
users to perform paragraph-based operations.
Cases where compatibility with Neovim's behavior is checked, cases where
there are known differences in behavior with Neovim (cases where the
landing position is other than the beginning of the line), and cases
where the Neovim behavior in the test suite seems strange are separated
in the test code so that they can be identified.
Release Notes:
- Added support for `ap` and `ip` paragraph text objects in Vim mode
([#7359](https://github.com/zed-industries/zed/issues/7359)).
`z.` is similar to zz but moves the cursor to the first non-blank
character.
From the documentation:
```
z. Redraw, line [count] at center of window (default cursor line). Put cursor at first non-blank in the line.
zz Like "z.", but leave the cursor in the same column.
```
Release Notes:
- Support the `z.` vim keybinding: Center cursor in window and put
cursor at first non-blank
This solves a major usability problem in Zed, that there's no way to
temporarily disable auto formatting without toggling the whole feature
off.
fixes https://github.com/zed-industries/zed/issues/5230
Release Notes:
- Added a new `workspace::SaveWithoutFormatting`, bound to `cmd-k s`, to
save a file without invoking the auto formatter.
Follow-up of
https://github.com/zed-industries/zed/issues/8651#issuecomment-1973411072
Zed current default is still to reuse the current window, but now it's
possible to do
```json
"alt-cmd-o": [
"projects::OpenRecent",
{
"create_new_window": true
}
]
```
and change this.
menu::Secondary confirm does the action with opposite window creation
strategy.
Release Notes:
- Improved open recent projects flexibility: settings can change whether
`menu::Confirm` opens a new window or reuses the old one
This PR adds settings for hiding title (breadcrumbs) from the terminal
toolbar. If the title is hidden, the toolbar disappears completely.
Example:
```json
"terminal": {
"toolbar": {
"title": true,
}
}
```
[The PR that added the "toolbar"
setting](https://github.com/zed-industries/zed/pull/7338) didn't affect
toolbars of the terminals that are placed in the editor pane. This PR
fixes that.
Release Notes:
- Added support for configuring the terminal toolbar ([8125](https://github.com/zed-industries/zed/issues/8125))
Following #7665, I've added a keymap to quickly hide and show gutter
line numbers.
`ctrl-l` and `cmd-l` were taken, so I've bound it to `cmd-;`.
https://github.com/zed-industries/zed/assets/138762/365d2a7c-b775-4486-8389-edafe59b2a87
Release notes:
- Added `editor: toggle line numbers` command and default keybindings
(`cmd-;` on macOS).
---------
Co-authored-by: Thorsten Ball <mrnugget@gmail.com>
This PR wires up support for [Azure
OpenAI](https://learn.microsoft.com/en-us/azure/ai-services/openai/overview)
as an alternative AI provider in the assistant panel.
This can be configured using the following in the settings file:
```json
{
"assistant": {
"provider": {
"type": "azure_openai",
"api_url": "https://{your-resource-name}.openai.azure.com",
"deployment_id": "gpt-4",
"api_version": "2023-05-15"
}
},
}
```
You will need to deploy a model within Azure and update the settings
accordingly.
Release Notes:
- N/A
This practice makes it difficult to locate todo!s in my code when I'm
working. Let's take out the bang if we want to keep doing this.
Release Notes:
- N/A
Even though I use Vim mode, I'd love to have this in the command
palette/fuzzy finder. It's an Emacs keybinding, but also supported by
macOS nearly everywhere.
Release Notes:
- N/A
I would like to keep diagnostics open on one side, and process them on
the other.
Release Notes:
- Added `editor::OpenExcerptsSplit` (bound to `cmd-k enter`) to open the
selected excerpts in the adjacent pane
- vim: Added `ctrl-w d`, `ctrl-w shift-d` and `ctrl-w space` for
`editor::GoTo{,Type}Definition` and `editor::OpenExcerptsSplit`
I would like to add these file icons all from the source svgrepo.com and
with a size of 14x14. Also I've modified file_types.json in order to add
the file types and path to the image aswell as added SQL as a storage
type so it's linked to an icon.
Here is how these new changes would look like:
<img width="240" alt="Captura de pantalla 2024-02-26 a las 19 30 33"
src="https://github.com/zed-industries/zed/assets/93369643/73e50e4a-bfe8-4239-b919-280150051e36">
Release Notes:
- Added icons for Coffeescript, F#, Nim, Scala, and TCL files.
- Updated icon for SQL files.
I'm not sure how compliant you're aiming to be with vim, but the `f`
behavior is more useful when it can search on multiple lines instead of
a single one, so I'd like to propose this change.
This change is quite frequent in vim/neovim as a plugin (e.g.
[clever-f](https://github.com/VSCodeVim/Vim),
[improved-ft](https://github.com/backdround/improved-ft.nvim), etc), and
in other vim emulations (e.g.
[vscode-vim](https://github.com/VSCodeVim/Vim)).
This PR formats the default `settings.json` file with Prettier.
This should help avoid unnecessary modifications in other PRs making
consequential changes to this file.
Release Notes:
- N/A
Reverts zed-industries/zed#7674
@ABckh: reverting this as it introduced a significant performance
slowdown, most likely caused by iterating through all the snapshot
entries to determine whether a directory is foldable/unfoldable/omitted.
It would be great if you could open a new PR that reverts this revert
and addresses the performance issues. Thank you!
/cc: @maxbrunsfeld
Release notes:
- N/A
I think this makes it less chaotic to edit text when the inlay hints are
on.
It's for cases where you're editing to the right side of an inlay hint.
Example:
```rust
for name in names.iter().map(|item| item.len()) {
println!("{:?}", name);
}
```
We display a `usize` inlay hint right next to `name`.
But as soon as you remove that `.` in `names.iter` your cursor jumps
around because the inlay hint has been removed.
With this change we now have a 700ms debounce before we update the inlay
hints.
VS Code seems to have an even longer debounce, I think somewhere around
~1s.
Release Notes:
- Added debouncing to make it easier to edit text when inlay hints are
enabled and to save rendering of inlay hints when scrolling. Both
debounce durations can be configured with `{"inlay_hints":
{"edit_debounce_ms": 700}}` (default) and `{"inlay_hints":
{"scroll_debounce_ms": 50}}`. Set a value to `0` to turn off the
debouncing.
### Before
https://github.com/zed-industries/zed/assets/1185253/3afbe548-dcfb-45a3-ab9f-cce14c04a148
### After
https://github.com/zed-industries/zed/assets/1185253/7ea90e42-bca6-4f6c-995e-83324669ab43
---------
Co-authored-by: Kirill <kirill@zed.dev>
a simple code for html tag support, I've only done the basics, and if
it's okay, I'll optimize and organize the code, and adapt other parts
like `is_multiline`, `always_expands_both_ways`, `target_visual_mode`,
etc
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Added support of auto collapsed directories, for example when directory
has only one directory inside we should display it as dir1/dir2 (#6935
). Please feel free to propose better solutions, as I am new in Rust
Demo:
https://streamable.com/seo3n9
Release Notes:
- Added support for auto-collapsing directories.
This PR formats the JSON files in the `assets/` directory with Prettier.
This should help avoid some of the changes in formatting when these
files are touched by contributors.
Release Notes:
- N/A
This PR adds a new `argument` vim text object, inspired by
[targets.vim](https://github.com/wellle/targets.vim).
As it's the first vim text object to use the syntax tree, it needed to
operate on the `Buffer` level, not the `MultiBuffer` level, then map the
buffer coordinates to `DisplayPoint` as necessary.
This required two main changes:
1. `innermost_enclosing_bracket_ranges` and `enclosing_bracket_ranges`
were moved into `Buffer`. The `MultiBuffer` implementations were updated
to map to/from these.
2. `MultiBuffer::excerpt_containing` was made public, returning a new
`MultiBufferExcerpt` type that contains a reference to the excerpt and
methods for mapping to/from `Buffer` and `MultiBuffer` offsets and
ranges.
Release Notes:
- Added new `argument` vim text object, inspired by
[targets.vim](https://github.com/wellle/targets.vim).
I think bold is the least fitting font weight for inlay hints, which
should be subtle hints and not, well, bold.
If someone feels strongly about this, I can revert, but only if we add
the ability to change this per theme.
Until then: beautiful, thin, subtle inlay hints!
Release Notes:
- Improved styling of inlay hints by not making them bold in the editor.
![screenshot-2024-02-23-17 30
29@2x](https://github.com/zed-industries/zed/assets/1185253/89c2a162-76bb-45cd-8b45-2a5bdf8ca87b)
I really think storybook is a cool standalone app but there are some
usability issues that are getting in the way of making this a fun tool
to use.
Currently it is not easy to gracefully exit out of storybook.
In fact even trying to Ctrl-c out of storybook seems currently broken to
me...
So the only real way to exit out of storybook is to kill the process
after a Ctrl-z.
This PR attempts to make this much easier by adding a simple app_menu
with a menu item called quit along with the ability to *Cmd-q* out of
storybook as well...
Both the menu item quit and *Cmd-q* gracefully exit storybook.
There are still a bunch of issues with storybook which I plan on
addressing in future PR's but this is a start and something that to me
is the highest priority to make storybook more functional and easy to
use moving forward.
One of my longer term goals of storybook is to have it be a nice stand
alone application similar to
[Loungy](https://github.com/MatthiasGrandl/Loungy) which can be used as
a nice tutorial application for how to develop a real world *gpui* app.
For that reason I added a *assets/keymaps/storybook.json* file as well.
Release Notes:
- vim: Added a setting to control default clipboard behaviour. `{"vim":
{"use_system_clipboard": "never"}}` disables writing to the clipboard.
`"on_yank"` writes to the system clipboard only on yank, and `"always"`
preserves the current behavior. ([#4390
](https://github.com/zed-industries/zed/issues/4390))
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
This changes the format of runnables slightly (the top-level object is
now a sequence, not a map).
The 2nd commit pulls in aliases from .zshrc and co.
Release Notes:
- N/A
Undoubtedly not perfect, but this should be something we can work off
of.
Note that matching keybindings with ctrl in them is currently broken on
linux (or at least x11). This keymap might just manage to be less useful
than using the macos one on linux until that is fixed... the proximate
cause of this is that the `key` field of the `Keystroke` struct looks
like `"\u{e}"` instead of `"n"` when `ctrl-n` is pressed.
Release Notes:
- N/A
Following up to #8079, this PR changes the default Markdown tab size to
2 spaces.
This should produce less surprising formatting for lists when using
Prettier.
Release Notes:
- Changed default Markdown tab size to 2 spaces.
This small inconsistency was mentioned on the discord. This fixes it.
Release Notes:
- Themes: Renamed `scrollbar_thumb.background` to
`scrollbar.thumb.background` to be consistent with other style
properties.
---------
Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
Part of #7108
This PR includes just the static runnables part. We went with **not**
having a dedicated panel for runnables.
This is just a 1st PR out of N, as we want to start exploring the
dynamic runnables front. Still, all that work is going to happen once
this gets merged.
Release Notes:
- Added initial, static Runnables support to Zed. Such runnables are defined in
`runnables.json` file (accessible via `zed: open runnables` action) and
they can be spawned with `runnables: spawn` action.
---------
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
Co-authored-by: Pitor <pitor@zed.dev>
Co-authored-by: Beniamin <beniamin@zagan.be>
This adds one feature I've been missing a lot in Vim mode: `gx` to open
the URL under the cursor.
Technically, in Vim, `gx` opens more "paths", not just URLs, but I think
this is a good start.
Release Notes:
- Added `gx` to Vim mode to open the URL under the cursor.
Demo:
https://github.com/zed-industries/zed/assets/1185253/6a19490d-b61d-40b7-93e8-4819599f6977
Activated by keystrokes g-e.
Release Notes:
- vim: Added `ge` and `gE` for go to Previous Word End.
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
This lets Go programmers configure `"code_actions_on_format": {
"source.organizeImports": true,
}` so that they don't have to manage their imports manually
I landed on `code_actions_on_format` instead of `code_actions_on_save`
(the
VSCode version of this) because I want to run these when I explicitly
format
(and not if `format_on_save` is disabled).
Co-Authored-By: Thorsten <thorsten@zed.dev>
Release Notes:
- Added `"code_actions_on_format"` to control additional formatting
steps on format/save
([#5232](https://github.com/zed-industries/zed/issues/5232)).
- Added a `"code_actions_on_format"` of `"source.organizeImports"` for
Go ([#4886](https://github.com/zed-industries/zed/issues/4886)).
Co-authored-by: Thorsten <thorsten@zed.dev>
Partially fixes#4321, since Azure OpenAI API can be converted to OpenAI
API.
Release Notes:
- Added `assistant.openai_api_url` setting to allow OpenAI API URL to be
configured.
---------
Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
- Open channel notes and chat on channel click
- WIP
- Fix compile error
- Don't join live kit until requested
- Track in_call state separately from in_room
Release Notes:
- Improved channels: you can now be in a channel without joining the
audio call automatically
**or**
- N/A
---------
Co-authored-by: Nathan Sobo <nathan@zed.dev>
This PR recognizes the following filetypes and provides them with
appropriate icons: `.avi .heic .j2k .jfif .jp2 .jxl .m4a .m4v .mkv .mka
.mov .opus .qoi .wma .wmv .wv`.
It also corrects `.ogg` to display an audio icon, not a video icon.
Though the container supports video, `.ogg` files are most commonly
found containing audio-only bitstreams likely due to the popularity of
the Vorbis audio codec. VSCode recognizes OGG files as audio.
Here is an exhaustive list of the file formats this PR aims to
recognize, with a subjective commonality rating attached to each:
- `.avi`: Audio Video Interleave. Multimedia container format for video
and audio data. **Rating: 7/10**
- `.heic`: High Efficiency Image Format. The same thing as `.heif`,
which is currently recognized. **Rating: 6/10**
- `.j2k`: JPEG 2000. Bitmap image format for lossy or lossless
compression. **Rating: 3/10**
- `.jfif`: JPEG File Interchange Format. Alternative JPEG extension that
sometimes pops up on the Web. **Rating: 5/10**
- `.jp2`: JPEG 2000 again, same rating.
- `.jxl`: JPEG XL. Modern, versatile image format growing in popularity.
**Rating: 5/10**
- `.m4a`: MPEG-4 Audio. Audio file format using AAC (lossy) or ALAC
(lossless) codecs. **Rating: 8/10**
- `.m4v`: MPEG-4 Video. Video container format developed by Apple
similar to MP4. **Rating: 4/10**
- `.mkv`: Matroska Video. Multimedia container format for video, audio,
and subtitle tracks. **Rating: 8/10**
- `.mka`: Matroska Audio. Audio file format supporting several types of
audio compression algorithms. **Rating: 3/10**
- `.mov`: QuickTime Movie. Multimedia container format developed by
Apple. **Rating: 8/10**
- `.opus`: Opus Audio. Audio coding format for efficient real-time audio
streaming. **Rating: 7/10**
- `.qoi`: Quite OK Image. Modern lossless image format for fast encoding
& decoding. **Rating: 1/10**
- `.wma`: Windows Media Audio. Audio file format developed by Microsoft.
**Rating: 6/10**
- `.wmv`: Windows Media Video. Video file format developed by Microsoft.
**Rating: 7/10**
- `.wv`: WavPack. Free, open-source lossless audio compression format
similar to FLAC. **Rating: 2/10**
Again note that the commonality rating is subjective and may vary based
on the specific use cases users have for Zed and their software
environments. I hope some of these will be considered, as having
flexible filetype recognition greatly adds to the feeling of
completeness in an editor at what appears to be very little cost. Thank
you!
Release Notes:
- Adds icon associations for more multimedia types [#7551](https://github.com/zed-industries/zed/issues/7551).
Previously it wasn't possible to create a keybinding for this action
because it required an argument.
Now the action takes the active item of the pane and if it's a
multi-buffer the first one.
This also adds a default keybinding for Vim mode: `-` will reveal the
file in the project panel.
Fixes#7485.
Release Notes:
- Added `pane::RevealInProjectPanel` as an action in the command
palette. ([#7485](https://github.com/zed-industries/zed/issues/7485)).
Co-authored-by: Antonio <antonio@zed.dev>
Release Notes:
- Improved Jetbrains keybindings to include cmd+alt+left/right to go
back and forwards between panes rather than the default previous / next
pane
Signed-off-by: James Gee <1285296+geemanjs@users.noreply.github.com>
Tried to match the existing file icons in Zed as much as possible. This
is how it looks:
| dark | light |
|---|----|
| <img width="183" alt="Screenshot 2024-02-06 at 15 03 57"
src="https://github.com/zed-industries/zed/assets/43472/bd862753-41bb-4ca6-9a44-16b9b1c9591c">
| <img width="180" alt="Screenshot 2024-02-06 at 15 03 14"
src="https://github.com/zed-industries/zed/assets/43472/9df8c589-64b6-49f2-8e15-b43126579a9f">
|
The main challenge is that the tangram is visually quite heavy and
detailed. The existing icons in Zed are designed in a 14px bounding box,
but are a bit smaller themselves. I guess the extra space is reserved
for hanging elements, it probably doesn't make sense to occupy the whole
area.
Simply scaling down an available SVG of the tangram didn't work well.
The individual shapes were not recognizable because the spacing between
them was too thin. I tried removing the spacing and applying different
opacities for each shape, but that didn't yield enough contrast between
the shapes either.
The second approach was to just use the outlines. It sort of worked, but
looked a bit messy in the places when the outlines are denser than the
tangram shapes:
| dark | light |
|---|----|
| <img width="192" alt="Screenshot 2024-02-05 at 22 55 46"
src="https://github.com/zed-industries/zed/assets/43472/d0029f49-675d-40ac-96d8-788a29706bad">
| <img width="195" alt="Screenshot 2024-02-05 at 22 56 05"
src="https://github.com/zed-industries/zed/assets/43472/d2de922a-70ec-4bd1-9033-db9a5201e9bd">
|
I then tried to remove the main outline and use the maximum space for
the tangram. That let me increase the spacing between the shapes. I also
rounded them a little bit, to make them look similar to other icons from
Zed. The end result looks clean and the shapes are still recognisable.
Approaches I tried next to an existing icon from Zed:
<img width="711" alt="Screenshot 2024-02-06 at 15 15 33"
src="https://github.com/zed-industries/zed/assets/43472/a3e4b0db-4b98-4072-91e8-fe71cff19adf">
Release Notes:
- Added file type icon for Elm
Terraform and HCL are almost the same language, but not quite so
proposing them as separate languages within Zed. (Terraform is an
extension of HCL, with a different formatter.)
This is just adding the language definition, parsing and highlighting
functionality, not any LSP or formatting beyond that for either
language.
I've taken a bunch of inspiration from Neovim for having the separate
languages, and also lifted some of their `scm` files (with attribution
comments in this codebase) as the tree-sitter repo doesn't contain them.
(Neovim's code is Apache-2.0 licensed, so should be fine here with
attribution from reading Zed's licenses files.) I've then amended to
make sure the capture groups are named for things Zed understands. I'd
love someone from Zed to confirm that's okay, or if I should clean-room
implement the `scm` files.
Highlighting in Terraform & HCL with a moderate amount of syntax in a
file (Terraform on left, HCL on right.)
<img width="1392" alt="Screenshot 2024-01-31 at 18 07 45"
src="https://github.com/zed-industries/zed/assets/696/1d3c9a08-588e-4b8f-ad92-98ce1e419659">
Release Notes:
- (|Improved) ...
([#5098](https://github.com/zed-industries/zed/issues/5098)).
This fixes `cmd+k` in the terminal taking 1s to have an effect. It is
now immediate.
It also fixes#7270 by ensuring that we don't set a bad state when
matching keybindings.
It matches keybindings per context and if it finds a match on a lower
context it doesn't keep pending keystrokes. If it finds two matches on
the same context level, requiring more keystrokes, then it waits.
Release Notes:
- Fixed `cmd-k` in terminal taking 1s to have an effect. Also fixed
sporadic non-matching of keybindings if there are overlapping
keybindings.
([#7270](https://github.com/zed-industries/zed/issues/7270)).
---------
Co-authored-by: Conrad <conrad@zed.dev>
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
This PR populates the `search.match_background` colors in the bundled
themes, using the values from the Zed1 themes.
Release Notes:
- Added theme-specific `search.match_background` colors to built-in
themes.
Turns out that these keybindings are active in Vim *and* in non-Vim mode
and they shadow `Ctrl-w` in terminals.
We should fix `Ctrl-w` being shadowed, but until then let's remove the
default keybindings.
Release Notes:
- N/A
Co-authored-by: Kirill <kirill@zed.dev>
Co-authored-by: Conrad <Conrad@zed.dev>
Adds settings for hiding breadcrumbs and quick action bar from
the editor toolbar. If both elements are hidden, the toolbar disappears
completely.
Example:
```json
"toolbar": {
"breadcrumbs": true,
"quick_actions": false
}
```
- It intentionally doesn't hide breadcrumbs in other views (for
instance, in the search result window) because their usage there differ
from the main editor.
- The editor controls how breadcrumbs are displayed in the toolbar, so
implementation differs a bit for breadcrumbs and quick actions bar.
Release Notes:
- Added support for configuring the editor toolbar ([4756](https://github.com/zed-industries/zed/issues/4756))
- Add a setting for `vertical_scroll_offset`
- Fix H/M/L in vim with scrolloff
Release Notes:
- Added a settings for `vertical_scroll_offset`
- vim: Fix H/M/L with various values of vertical_scroll_offset
---------
Co-authored-by: Vbhavsar <vbhavsar@gmail.com>
Co-authored-by: fdionisi <code@fdionisi.me>
This change makes it so that if you are the first to join a channel,
your project is automatically shared.
It also makes it so that if you join a channel via a link and there are
no shared projects, you open the notes instead of an empty workspace
with nothing.
This is to try and address the discoverability of project sharing: we've
had
two reviews that have talked about channels, but not talked about
sharing
projects into them, which makes me suspect they didn't know about the
feature.
Release Notes:
- Added a setting `share_on_join` (defaulting to true). When set, and
you join an empty channel, your project is automatically shared.
This PR implements support for displaying diagnostics in the scrollbar,
similar to what is already done for search results, symbols, git diff,
...
For example, changing a field name (`text`) without changing the
references looks like this in `buffer.rs` (note the red lines in the
scrollbar):
![image](https://github.com/zed-industries/zed/assets/53836821/c46f0d55-32e3-4334-8ad7-66d1578d5725)
As you can see, the errors, warnings, ... are displayed in the scroll
bar, which helps to identify possible problems with the current file.
Relevant issues: #4866, #6819
Release Notes:
- Added diagnostic indicators to the scrollbar