Stash views
A stash is a named collection of paths that persists across directory changes, giving you a scratch space or bookmark list where you can gather files from different trees and act on them together.
Actions
Every stash is addressed by name, with "" as the unnamed default stash. Three bind actions operate on stashes: Stash(name) pushes marked rows (or the working directory when the prompt is focused), backs out if you are already inside that stash, and opens the stash view otherwise; PushStash(name) adds rows without leaving the current view; and OpenStash(name) switches directly to the stash view.
By default, alt-s is bound to Stash (the unnamed transient stash) and alt-b is bound to Stash(bookmark) (a persistent bookmark stash).
Storage and duplicates
Each stash sets its storage mode (kind) and duplicate policy (insert) under [views.stashes.<name>] in config.toml. Rows always appear newest-first.
kind | Backing store | Missing paths on disk |
|---|---|---|
"transient" (default) | Process memory | Cleared on exit |
"filter" | History database | Hidden on load, kept in DB |
"prune" | History database | Deleted from DB on load |
When you push a path that is already in the target stash, insert decides what happens:
insert | Duplicate behavior |
|---|---|
"replace" (default) | Existing row replaced at top with fresh time |
"skip" | Existing row kept, duplicate push ignored |
"duplicate" | Additional row inserted for the same path |
Cross-directory workflows
Stashes are f:st's primary tool for operations that span multiple directories:
To archive, diff, or convert files across directories, mark them with tab and press alt-s in each directory, press alt-s with nothing selected to open the stash, select all with ctrl-a, and run a menu action such as compress: zip or diff from alt-e. You can also collect paths while browsing, open the stash to review or prune them, cut or copy the subset you want (ctrl-x / ctrl-c), return to your destination directory, and paste (ctrl-v).
Configuring stashes
Define any number of named stashes under [views.stashes.<name>] in config.toml:
[views.stashes.""]
prompt = "stash> "
kind = "transient"
insert = "replace"
[views.stashes.bookmark]
prompt = "★> "
prompt_style = { fg = "Yellow" }
kind = "filter"
insert = "skip"Referencing a stash name in Stash(name) that has no table in config.toml creates a transient, replace-mode stash on the fly.