Quick note workflow (ephemeral untitled tabs)
May 20, 2026 · View on GitHub
Default-on editor mode (Settings.quick_note_workflow, Settings → Files): reduces friction for pathless “scratch” tabs. Turn off in settings to restore the classic save confirmation for new tabs.
Behavior
- Quit: Modified untitled tabs (no file path) do not block exit. Saved files on disk still use the normal prompt when modified.
- Close tab: Modified untitled tabs with content still show the unsaved-changes dialog (Save / Don't save / Cancel). Empty untitled tabs close silently.
- Persistence: Unsaved text is not written to a normal file path; it is still captured by the existing session pipeline (
session.json,session.recovery.json, and per-tab files under the config dirrecovery/). Requires Restore previous session on startup so the next launch reloads those buffers. - Display names:
Tab.untitled_display_nameholds an optional label. The tab strip shows it instead of “Untitled”. Double-click an untitled document tab to open the rename dialog. The name is stored in session metadata (SessionTabState.display_titlewithout a*suffix). - Save As: Assigning a path clears
untitled_display_nameon save (real file name comes from disk).
Code touchpoints
Tab::should_prompt_to_save(&Settings, SavePromptContext)— returnsfalsefor pathless tabs whenquick_note_workflowis true only forSavePromptContext::AppExit.AppState::close_tab()— usesSavePromptContext::TabCloseso scratch tabs with content still prompt.AppState::has_unsaved_changes()— usesAppExitsorequest_exit()does not block on scratch tabs.AppState::resolve_tab_content— pathless tabs withhas_unsaved_content == falserestore as empty buffers (supports multiple empty untitled tabs in session).AppState::capture_session_state— usesTab::persisted_session_display_title()for stable session titles (no trailing*).
Caveats
- This is the same in dev (
cargo run) and installed builds: persistence uses your Ferrite config directory, not the project folder. - On clean exit, the app saves
session.jsonand per-tab bodies underrecovery/. Older versions deletedrecovery/on exit, which broke restoring pathless tabs; that is fixed by keeping recovery content and only removing the crash snapshot file (session.recovery.json). - Closing a modified untitled tab via Don't save discards that buffer from the open session; Save runs Save As. Other open scratch tabs remain in the session for the next run.
- Turning Quick note workflow off restores the original save prompts for new tabs; existing session data is unchanged.