Skip to content

Add workspace history with :workspace-history picker - #16368

Open
WantenMN wants to merge 1 commit into
helix-editor:masterfrom
WantenMN:workspace-history
Open

WantenMN wants to merge 1 commit into
helix-editor:masterfrom
WantenMN:workspace-history

Conversation

@WantenMN

@WantenMN WantenMN commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Records recently opened workspace roots so they can be listed and jumped back to, similar to VS Code's Open Recent.

image

What this adds:

  • New helix-loader::workspace_history module storing an array of {path, last_seen} at data_dir()/workspace_history.json (atomic write, best-effort: IO failures only warn, never break :cd or startup). Prunes missing directories, caps entries.
  • Recording hooks: Editor::set_cwd (covers :cd/:pushd/:popd) and application startup.
  • [editor.workspace-history] config (enable, max-entries).
  • Picker + commands: normal-mode workspace_history_picker, typed :workspace-history and :workspace-history-clear. Bare queries match a combined name + path primary column (bare text only filters the primary column, see PickerQuery); opened column is display-only.
  • Docs regenerated via cargo xtask docgen, plus an editor.md section.

Testing:

  • 6 new unit tests in workspace_history (upsert ordering, truncation, pruning, broken-file tolerance, disabled noop).
  • cargo check -p helix-term, cargo fmt clean.
  • Manual pty smoke tests: startup record, :cd record, picker lists entries and filters by both name and path fragments, clear removes the file.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant