Show a file in its folder and copy its path
Open the folder of the file you are reading with the file selected, or copy the file's full path, from the tab menu, the command palette, or a shortcut.
Two actions work on any open file:
- Show it in its folder. The name follows your system:
- Mac: Reveal in Finder. Finder opens with the file selected.
- Windows: Show in Explorer. File Explorer opens with the file selected.
- Linux: Open containing folder. Your file manager opens the folder the file is in.
- Copy path. The file's full path goes on the clipboard, ready to paste into a terminal or another app. After the copy succeeds, the top bar briefly says Copied on its left, and screen readers announce it. The document stays in place.
The path is the same one the tab shows when you hover over it, for example /Users/jane.doe/notes/plan.md or C:\Users\Jane Doe\notes\plan.md.
Shortcuts
These work from anywhere in the window and act on the tab you are looking at.
| To | Mac | Windows and Linux |
|---|---|---|
| Show in folder | Cmd + Option + R | Shift + Alt + R |
| Copy path | Cmd + Option + C | Shift + Alt + C |
| Open the command palette | Cmd + Shift + P | Ctrl + Shift + P |
Where to find them
There is no path row under the tabs: the document starts right below them. Hover over a tab to see its full path; screen readers read it too.
- The tab menu. Right-click a tab. With the keyboard, move to a tab and press the Menu key or Shift + F10. Use the arrow keys to pick an action and Enter to run it; Escape closes the menu. The menu acts on that tab, even if it is not the one you are looking at. It also has Close Tab.
- The command palette. Press Cmd + Shift + P (Mac) or Ctrl + Shift + P (Windows, Linux). Type to filter, use the arrow keys to pick, and press Enter to run. Escape closes it. Besides these two actions it lists Open, Close Tab, Turn on (or off) Changes, and Next and Previous Tab.
The command palette opens below the tabs, even with larger text.
Each menu and the palette show the shortcut next to the action.
When the file is gone
If the file was moved or deleted since you opened it:
- The show-in-folder action shows the nearest folder that still exists and tells you which one, for example "File not found. Opened /Users/jane.doe/notes." On a Mac, Finder shows that folder selected in the folder above it.
- Copy path still copies the path the file had.
If the file was already gone when Sashmark reopened your tabs at launch, Sashmark never read it, so the show-in-folder action says "Could not show the folder" instead. Copy path still works.
When no folder opens
If your system cannot open a file manager (on Linux, for example, when none is set up), Sashmark says "Could not show the folder" with the reason, such as "xdg-open exited with exit status: 3". On Windows, Sashmark cannot tell whether File Explorer opened, so it does not say.