Skip to content

feat(sidebar): reveal workspace folders in Finder and file managers - #1779

Open
mondary wants to merge 4 commits into
sheprd-labs:mainfrom
mondary:pr/reveal-workspace
Open

mondary wants to merge 4 commits into
sheprd-labs:mainfrom
mondary:pr/reveal-workspace

Conversation

@mondary

@mondary mondary commented Nov 30, 2026

Copy link
Copy Markdown
Contributor

What

A local workspace menu now offers Reveal in Finder on macOS and Reveal in File Manager on Linux. Retained project rows expose the same action; remote workspaces and Windows builds keep their existing menus.

The action is optional, so it never blocks the rest of the menu on platforms where it does not exist. This is the remaining Finder piece from #1711, extracted on current main after its retention work landed via #1771.

Testing

  • cargo check --locked -p sheprd-gpui
  • cargo test --locked -p sheprd-gpui --lib workspace_tests::reveal (1 passed)
  • cargo clippy --locked -p sheprd-gpui --all-targets
  • cargo fmt --all -- --check, check-sorted, check-file-size, check-i18n

A local workspace menu now offers Reveal in Finder on macOS and Reveal in File Manager on Linux, using the folder captured for the menu target. The same row is offered for retained projects. Remote rows and Windows builds keep their existing menus; the reveal action is optional and never blocks the rest of the menu.

Adds a menu test for a local workspace. Checked with cargo check, cargo test --locked -p sheprd-gpui --lib workspace_tests::reveal, cargo clippy --all-targets, cargo fmt, check-sorted, check-file-size and check-i18n.
@mondary
mondary requested a review from penso as a code owner November 30, 2026 08:53
@greptile-apps

greptile-apps Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

Confidence Score: 4/5 · The PR appears safe to merge, with a non-blocking fix needed for workspaces that have no saved folder.RetriggerView in GreptileConfidence Score: 4/5

[Medium impact] The change affects a bounded workspace-menu action on macOS and Linux.

The PR appears safe to merge, with a non-blocking fix needed for workspaces that have no saved folder.

Findings

  1. P2 Reveal has no folder ▶

Summary

Adds a Reveal action to local workspace menus on macOS and Linux.

  • Local workspace menus can reveal their folders in the file browser.

Reviews (1) · Last reviewed commit: "feat(sidebar): reveal workspace folders ..." · Reviewed by Greptile

Comment on lines +8 to +10
if self.selected_is_remote() {
return None;
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Reveal has no folder

reveal_item() offers Reveal even when the workspace has no folder. App-kept workspaces can have an empty cwd, including the default workspace. Clicking Reveal passes an empty path to open or xdg-open and closes the menu without revealing a workspace folder. Hide the action when the target's cwd is empty, and add a test for that case.

Suggested change
if self.selected_is_remote() {
return None;
}
if self.selected_is_remote()
|| self.menu.target.as_ref().is_none_or(|target| target.cwd.is_empty())
{
return None;
}

The workspace menu draws the reveal action as a header icon, like the mute toggle, so the pull request card stays visible in short windows. The retained menu keeps its own rows, and the compact-menu test now counts header actions dynamically.
… open

The reveal action sits beside the branch and backend line, sized so the header never grows, and it leaves the menu open like the mute toggle. The compact-menu test counts header actions dynamically and walks past both header actions.
The detail line looks up any non-mute header action, so Windows builds without the reveal variant still compile.

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