From 0b4cfd4b416d03ef64ccd908dfee810c6a498569 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Mon, 9 Nov 2026 23:15:39 -0300 Subject: a session's end leaves a slim dump and History lists them, the tags gain Follow, History and the window's Fonts: every way out (Exit, the last pane's Del, the host's quit) runs Pardes.endSession, which puts a dump of the session in the state file under the usual label before quitting, slim by the dump's own means (dumpJoin's slim_terminals, and Store's slim-file swap now a Slim struct: no undo, a clean file's text read from its file again by revivePane, a terminal a size for a new shell), none for a session of shells alone; the dump's image carries the panes' names, which /dumps rows end with; the History builtin (SPC f h) lists the state file's dumps in a +History pane and a look at a row is a Restore of its label; the default tags: Follow after Collapse on text panes, History before Debug on the workspace row, Fonts after Themes in a window's view alone (tagline.topbarDefault picks the row per view; both rows are known defaults to the docs and tutor tests); the tty goldens re-recorded (the new words; a narrow pane's tag wraps to a second row, so its body rows shift), builtins JSON regenerated Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge --- src/config.zig | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'src/config.zig') diff --git a/src/config.zig b/src/config.zig index 96a5f557..3a846206 100644 --- a/src/config.zig +++ b/src/config.zig @@ -141,6 +141,7 @@ pub const leader_path = paths: { .Forward = "ji", .Last = "jj", .Jumplist = "jl", + .History = "fh", .Look = null, .Mini = null, .Exec = null, @@ -230,14 +231,18 @@ pub const child_term = "xterm-256color"; pub const child_colorterm = "truecolor"; pub const child_term_program = "pardes"; -pub const topbar_str = "Newcol Joincol Find Grep Help Changelog Tutor Dump Themes Config Debug Exit"; +// Fonts is the window's word alone (the font picker), so a terminal build's +// row has no such builtin to name: the window's row and the terminal's. +pub const topbar_window_str = "Newcol Joincol Find Grep Help Changelog Tutor Dump Themes Fonts Config History Debug Exit"; +pub const topbar_terminal_str = "Newcol Joincol Find Grep Help Changelog Tutor Dump Themes Config History Debug Exit"; +pub const topbar_str = if (@import("builtins.zig").capabilities.font_picker) topbar_window_str else topbar_terminal_str; -pub const pane_builtins_str = "Term Collapse Del"; -pub const file_pane_builtins_str = "Save Term Collapse Del"; +pub const pane_builtins_str = "Term Collapse Follow Del"; +pub const file_pane_builtins_str = "Save Term Collapse Follow Del"; /// After a file's, on one a language server speaks for. pub const lsp_pane_builtins_str = "Def Refs"; /// A diff's (a .diff, a .patch, a +Pager holding one): Diff. -pub const diff_pane_builtins_str = "Save Term Diff Collapse Del"; +pub const diff_pane_builtins_str = "Save Term Diff Collapse Follow Del"; /// A +Pager's (`pardes -`): Filter, as a terminal's. pub const pager_pane_builtins_str = "Save Term Filter Collapse Del"; /// A +Pager holding a diff (`git show`): Diff too. @@ -431,6 +436,7 @@ pub const search_buffer = "+Search"; pub const help_buffer = "+Help"; pub const dump_config_buffer = "+DumpConfig"; pub const jumps_buffer = "+Jumps"; +pub const history_buffer = "+History"; pub const preview_buffer = "+Preview"; pub const unsaved_buffer = "+Unsaved"; pub const themes_buffer = "+Themes"; @@ -1544,7 +1550,8 @@ const doc_typ = struct { if (w.end > 0) w.writeByte(' ') catch return false; w.writeAll(x[0 .. std.mem.indexOfScalar(u8, x, '+') orelse x.len]) catch return false; } - const tags = [_][]const u8{ topbar_str, @import("tagline.zig").column_tag_default, pane_builtins_str, file_pane_builtins_str, diff_pane_builtins_str, pager_pane_builtins_str, pager_diff_pane_builtins_str, diff_view_builtins_str, terminal_pane_builtins_str, command_pane_builtins_str, dir_pane_builtins_str }; + // Both rows: the docs and the tutor show the window's and the terminal's. + const tags = [_][]const u8{ topbar_window_str, topbar_terminal_str, @import("tagline.zig").column_tag_default, pane_builtins_str, file_pane_builtins_str, diff_pane_builtins_str, pager_pane_builtins_str, pager_diff_pane_builtins_str, diff_view_builtins_str, terminal_pane_builtins_str, command_pane_builtins_str, dir_pane_builtins_str }; for (tags) |d| if (std.mem.eql(u8, d, w.buffered())) return true; // A kind's pane's: Term, its addon's words, Collapse Del (Kind.zig). const shown = w.buffered(); -- cgit v1.3