editor: Add file permalink support to tabs and the Project Panel (#62177)

# Objective

- Add file-level hyperlink support for opening and copying hyperlinks
for Git remote source control to project panel and tabs
- Unify the language for Git remote hyperlinks across blame, project
panels, and tabs to be similar to GitLens' definitions (which are
commonly used in VS Code)

## Solution

- Updated the Git crate to expose relevant metadata to surface new
options within the editor
- Added new options for `Open File on Remote` and `Copy Remote File URL`
to project panel/file explorer and file tabs
- Altered the blame UI options to be consistent with new labels / more
clear

## Testing

- Ran `cargo run` to boot app and manually smoke test (see proof below)
- Added unit tests for this change

## Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content adheres to Zed's UI standards
([UX/UI](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
and
[icon](https://github.com/zed-industries/zed/blob/main/crates/icons/README.md)
guidelines)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable

## Showcase



https://github.com/user-attachments/assets/d600ca4f-47e7-438c-90e1-f40124a606b4

---

Release Notes:

- Added options to open or copy whole-file permalinks from file tabs and
the Project Panel.

---------

Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
This commit is contained in:
Jacob WolfandSmit Barmase authored and GitHub committed 2026-08-26 18:21:33 +00:00
1 parent a3c4abf07c
commit 3ba893e4ac
16 files changed
+491 -57

No files matched your search

+9 -5
View File
@@ -367,12 +367,16 @@ You can configure multiple custom providers if you work with several self-hosted
### Permalinks
Zed also has a Copy Permalink feature to create a permanent link to a code snippet on your Git hosting service.
Zed can open or copy a permanent link to a file or code selection on your Git hosting service.
These links are useful for sharing a specific line or range of lines in a file at a specific commit.
Trigger this action via the [Command Palette](./getting-started.md#command-palette) (search for `permalink`),
by creating [custom key bindings](./key-bindings.md#custom-key-bindings) for the
`editor::CopyPermalinkToLine` or `editor::OpenPermalinkToLine` actions
or by simply right clicking and selecting `Copy Permalink` with line(s) selected in your editor.
For the current selection in the editor, use {#action editor::CopyPermalinkToLine} or
{#action editor::OpenPermalinkToLine} from the [Command Palette](./getting-started.md#command-palette)
(search for `permalink`), via [custom key bindings](./key-bindings.md#custom-key-bindings),
or by right-clicking and selecting **Copy Permalink to Line**.
From a file tab or the Project Panel, you can also **Open File Permalink** or **Copy File Permalink**
for the whole file (without a line selection).
## Diff Hunk Keyboard Shortcuts