Skip to content

In helix mode, on zed, Ctrl-s saves the file instead of saving selection to a jumplist as it should #41580

@luccahuguet

Description

@luccahuguet

Summary

In helix mode, on zed, Ctrl-s saves the file instead of saving selection to a jumplist

Description

In regular helix, ctrl-s does not save the file. For that we have :write, which is already present and working well in Zed. Instead, in regular helix, ctrl-s serves the purpose of saving that selection to the jump-list, that we can walk through forwards or backwards using ctrl-i and ctrl-o.

Zed already supports jumplists, so all that is left is to re-bind ctrl-s to to that instead.

Zed's jumplist system does not seem to work with selections as it is, but that is ok. We should focus on getting a basic version of this working, and cater to the selection aspect of the helix's jumplist in a separate issue following this one.

Steps to reproduce:

press ctrl-s on zed, on helix mode, with a file open

Expected Behavior:

Pressing Ctrl+S saves the current cursor position to the jumplist, allowing the user to navigate back to this position using Ctrl+O (backward) and Ctrl+I (forward), consistent with regular Helix's behavior.

Actual Behavior:

Pressing Ctrl+S saves the file instead of saving the position to the jumplist, which is the default Zed behavior rather than the expected Helix mode behavior.

Future Expected Behavior:

After this issue is completed, we can focus on not only saving the cursor position, to the jumplist, but also the selection. As in true helix.

Zed Version and System Specs

Zed: v0.210.4 (Zed)
OS: Linux Wayland pop 24.04
Memory: 31.1 GiB
Architecture: x86_64
GPU: NVIDIA GeForce RTX 3050 6GB Laptop GPU || NVIDIA || 580.82.09

Relevant PRs

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions