From c40d447e63663d947f241d60a2bdb8ce1bd141c0 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Tue, 24 Nov 2026 19:28:29 -0300 Subject: messages: one notice row at the window's foot indexes the live messages, and the chips over the bodies go (pick-ui SPEC §10.3, walk UI line C item 2): the panes' area ends a row higher (layout.noticeRowHeight, none on a screen under 3 rows, as the column tags); the row is a header layer of its own (Layer.Kind.notice_row, NOTICE_ROW_LAYER, Region.Kind.notice_row) in the workspace tag's colours: on the left the message the row leads with (error > question > warn > notice > echo, the newest within a rank: its glyph in its kind's ink, its cause unless its words name it, its words without a host's clock stamp, ×n, its places as words), dimmed once its bright time is over; on the right +N more, N questions · SPC e, SPC e walk for an error with places, or N messages · SPC h m; with nothing live the focused pane's path:line (a terminal's directory); built each frame from the state (Messages.noticeRow, bounded by notice_row_cap), the left part giving way to the right; B2 runs and B3 Looks at a word on it (mouse.zig); Pane.Notices keeps the leader's and a prompt's chips only; a latent fault found by it: a kind's pane reopened (its file changed on disk, a Restore) kept the hashes of the views its old state was told, so the new state was never told its view and a PDF stayed blank until something moved its pane; the reloaded message's chip used to move it (Kind.reopen now tells a new state every view; behaviour addons_pdf's disk-change and Restore tests, failing before the fix); a message's cause for a kind's pane is its path; every frame changes (the foot row): boot's foot reads '/tmp/pardes-snap/boot/cwd', msg's 'repainted' '· saved /tmp/pardes-snap/msg/cwd/a.txt 2 messages · SPC h m' where a chip stood on the body's first row; the 98 tty goldens rewritten and read (57 the rows shifted alone, the rest the chips gone and racy shell output re-recorded; no file-written block and no snapshot's name changed), the four tty cases that click at fixed rows given a row more (chordcut, layout-open, images, respawn: their cursors unchanged), the addon scripts' outputs (fake, snake, life, pdf: windows a row shorter, the chip gone), hxdiff's core a row taller (22 rows as helix's), the tests over tiny screens a row taller, the drag edge of a bottom pane over the notice row (mouse.zig); tests: Messages.zig 'the notice row leads with the most important live message ...', 'a builtin announces itself on the notice row, an echo ...', draw.zig 'the word under the pointer on the notice row is lit ...', 'a message wider than the notice row ... gives way to the row's right end'; tui gate: core-test, pane-test, shell-test, behaviour-test (and --replay: 20 seeds, 0 failures), term-test, kitty-test pass; process-test 0 of 146 failed; the gui build is gated at the line's end MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 --- test/snapshots/filewatch.golden | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'test/snapshots/filewatch.golden') diff --git a/test/snapshots/filewatch.golden b/test/snapshots/filewatch.golden index 26ba330d..1e10ec08 100644 --- a/test/snapshots/filewatch.golden +++ b/test/snapshots/filewatch.golden @@ -17,7 +17,6 @@ | 9 line 9 | 10 line 10 | 11 line 11 -| 12 line 12 | /tmp/pardes-snap/filewatch/cwd/sub/s.txt Save Term Collapse Follow Del | 1 line 1 | 2 line 2 @@ -28,15 +27,19 @@ | 7 line 7 | 8 line 8 | ~ +| +| +| · @p1 a copy of the terminal's text: Tab or B2 runs it; what the program draws next replaces it (Ctrl-b types to the program) 1 message · SPC h m == snap kept grid=210x31 cursor=15,7 -|7: 1 liMYEDITne 1 /tmp/pardes-snap/filewatch/cwd/w.txt changed on disk (get reloads it, Save overwrites it) +|30: · /tmp/pardes-snap/filewatch/cwd/w.txt changed on disk (get reloads it, Save overwrites it) 2 messages · SPC h m == snap reloaded_sub grid=210x31 cursor=15,7 -|20: 1 RENAMED --:--:-- reloaded /tmp/pardes-snap/filewatch/cwd/sub/s.txt -|21: ~ +|19: 1 RENAMED +|20: ~ +|21: |22: |23: |24: |25: |26: |27: -|28: +|30: · reloaded /tmp/pardes-snap/filewatch/cwd/sub/s.txt 3 messages · SPC h m -- cgit v1.3 From e91261ff4f4602afec14d2fb958fd3e51a4dc62d Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Tue, 24 Nov 2026 21:01:37 -0300 Subject: messages: a background question waits in its pane's tag and never takes the keyboard; SPC e gives it the keyboard, Esc leaves it waiting (pick-ui SPEC §10.2, §10.4, §3.2 asking, walk UI line C item 4): a file that changes on disk under unsaved text is now a question of its pane (one at a time: File.changed), its answers r Reload, k Keep mine and d Diff (Messages.Ask.answers); while the tag is at rest the question is drawn after the path as computed prefix text, 'changed on disk ▸ r Reload k Keep mine d Diff · SPC e to answer' (Messages.askingText; the tag's own words stay after it until the head of ruling R1 takes their place), its mark ? in the box and the notice row's '1 question · SPC e'; the keys stay the body's: View.answering (a pane's serial, the view's own keyboard state, ruling R4) is set by SPC e (item 5) and makes the answer's key answer it in handleKey's first slot, Esc leaving it waiting; the own-command questions (Del's side, a REPL's choice) keep that slot as they were; B2 on an answer's word in its tag answers it (exec.execute: Messages.answerWord); r reads the file again with the consent Get would ask for, k keeps the text and says so, d reads the disk's text (the host's read, taped) and shows where it parts from the buffer as ghost rows under that line, the disk's + lines first (Messages.diskDiff, Said.open: shown whatever the caret), d again hides them; an answer is logged ('... · answered Reload'); Messages.waitingAnswers is what a : lists first (for agent E); 9P /log says 'msg N changed on disk' (monkey9p's checker reads that); tests: Messages.zig 'a file changed on disk under unsaved text asks in its tag and never takes the keyboard: SPC e's keyboard answers, d shows the disk's lines as ghosts, Esc leaves it waiting, B2 on Reload reads it again', ninep/ctl.zig's disk-change test now finds the question; tui: core-test, shell-test, pane-test, behaviour-test pass; process-test: filewatch's golden takes the question (its tag row and its notice row), Restore's root-ctl case failed once under load and passes alone MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 --- core/Core.zig | 4 + core/File.zig | 5 +- core/Messages.zig | 192 ++++++++++++++++++++++++++++++++++++++++ core/exec.zig | 2 + core/keys.zig | 17 ++++ core/ninep/ctl.zig | 4 +- core/tagline.zig | 7 +- test/monkey9p.zig | 2 +- test/snapshots/filewatch.golden | 5 +- 9 files changed, 231 insertions(+), 7 deletions(-) (limited to 'test/snapshots/filewatch.golden') diff --git a/core/Core.zig b/core/Core.zig index 27a0da4f..92c81ba6 100644 --- a/core/Core.zig +++ b/core/Core.zig @@ -177,6 +177,10 @@ pub const View = struct { /// A key that waits for the next: the leader (SPC) or the window prefix /// (Ctrl-w), one at a time. prefix: enum { none, leader, window } = .none, + /// A background question SPC e gave the keyboard: the serial of the + /// pane it waits on (0: none). Its next key answers it; Esc leaves it + /// waiting (keys.zig handleKey). + answering: u32 = 0, /// The register the running normal command names (`"`); 0 for the /// default one. register: u21 = 0, diff --git a/core/File.zig b/core/File.zig index 58544b62..f611bbbd 100644 --- a/core/File.zig +++ b/core/File.zig @@ -2439,8 +2439,9 @@ pub fn changed(p: *Pardes, id: u8, bytes: []const u8) void { if (f.disk_newer == disk) return; f.disk_newer = disk; f.disk_newer_warned = false; - var said: pardes.Kind.Buf(limits.host_path_cap + 64) = .{}; - p.setMessage(.at(id), said.print("{s} changed on disk (get reloads it, Save overwrites it)", .{f.path[0..@min(f.path.len, limits.host_path_cap)]})); + // A question in its tag, never the keyboard's (pick-ui SPEC §10.2): + // one waiting already is the one about it. + if (p.messages.waiting(pane) == null) pardes.Messages.say(p, .question, id, "changed on disk").asks = .disk; var rec: [16]u8 = undefined; pardes.ctlfs.events.notePath(p, "changed", std.fmt.bufPrint(&rec, "{d}", .{pane.serial}) catch unreachable); // a u32 fits 16 return; diff --git a/core/Messages.zig b/core/Messages.zig index 282482ea..e421a32c 100644 --- a/core/Messages.zig +++ b/core/Messages.zig @@ -104,8 +104,19 @@ pub const Ask = enum(u8) { none, /// A file changed on disk under unsaved text. disk, + + /// Its answers, as its pane's tag offers them: the key that gives one, + /// and its word (an Exec of the word's first word gives it too). + pub fn answers(a: Ask) []const Answer { + return switch (a) { + .none => &.{}, + .disk => &.{ .{ .key = 'r', .word = "Reload" }, .{ .key = 'k', .word = "Keep mine" }, .{ .key = 'd', .word = "Diff" } }, + }; + } }; +pub const Answer = struct { key: u8, word: []const u8 }; + /// One live message. pub const Said = struct { pub const replica = .{ .len = .{ .{ "places", "places_len" }, .{ "detail", "detail_len" } } }; @@ -125,6 +136,9 @@ pub const Said = struct { /// The serial of the pane it is about, 0 for none in particular. pane: u32 = 0, asks: Ask = .none, + /// Its detail shown under its first place's line whatever the caret + /// (a question's Diff). + open: bool = false, /// How many times in a row it was said. n: u16 = 1, /// When it was last said, on the core's clock (`Pardes.clock.now_ns`). @@ -472,6 +486,135 @@ fn placeOf(row: []const u8) ?struct { path: []const u8, line: u32, col: u32, tex return null; } +/// The question waiting on `pane`, an index into `live`; null for none. +pub fn waiting(m: *const Messages, pane: *const Pane) ?usize { + for (m.live[0..m.live_len], 0..) |*s, i| if (s.kind == .question and s.pane == pane.serial) return i; + return null; +} + +/// The answers of the question waiting on `pane`: what a `:` lists first +/// (pick-ui SPEC §10.4); none without one. +pub fn waitingAnswers(m: *const Messages, pane: *const Pane) []const Answer { + const i = m.waiting(pane) orelse return &.{}; + return m.live[i].asks.answers(); +} + +/// The waiting question's words as its pane's tag asks them, while the tag +/// is at rest (SPEC §3.2 asking): what it asks, its answers, and how to +/// give one. `answering`: SPC e gave it the keyboard. +pub fn askingText(m: *const Messages, pane: *const Pane, answering: bool, out: []u8) []const u8 { + const i = m.waiting(pane) orelse return ""; + const s = &m.live[i]; + var w: std.Io.Writer = .fixed(out); + w.print("{s} \u{25b8}", .{s.words()}) catch {}; + for (s.asks.answers()) |a| w.print(" {c} {s} ", .{ a.key, a.word }) catch {}; + w.writeAll(if (answering) "\u{b7} Esc later" else "\u{b7} SPC e to answer") catch {}; + return w.buffered(); +} + +/// Answer live question `i` with `key`: `r` reads the file again over its +/// unsaved text, `k` keeps the text and lets the disk's be, `d` shows (or +/// hides again) the disk's lines where they differ, as ghosts in its +/// body. False for a key that is none of its answers. +pub fn answer(p: *Pardes, i: usize, key: u8) bool { + const m = &p.messages; + const s = &m.live[i]; + const a = for (s.asks.answers()) |a| { + if (a.key == key) break a; + } else return false; + p.needs_frame = true; + const id = p.paneBySerial(s.pane) orelse { + m.remove(i); + return true; + }; + var said: Buf(256) = .{}; + if (key == 'd') { + if (s.open) { + s.open = false; + return true; + } + diskDiff(p, s, id); + return true; + } + logMessage(p, id, .echo, said.print("{s} {s} \u{b7} answered {s}", .{ s.src.slice(), s.words(), a.word })); + m.remove(i); + if (key == 'r') { + const pane = p.panes[id].?; + // The answer is the consent Get would ask for. + if (pane.file) |f| pane.discard_warned = .{ .revision = f.revision, .by = .get }; + pardes.exec.runBuiltin(p, .Get, id, "", null); + } else _ = say(p, .echo, id, "kept yours; the disk's is not read"); + return true; +} + +/// An Exec of an answer's word in the tag of a pane a question waits on +/// (B2 on `Reload`): that answer. False for any other word. +pub fn answerWord(p: *Pardes, id: usize, word: []const u8) bool { + if (id >= MAX_PANES) return false; + const pane = p.panes[id] orelse return false; + const i = p.messages.waiting(pane) orelse return false; + const typed = std.mem.trim(u8, word, " \t\r\n"); + for (p.messages.live[i].asks.answers()) |a| { + const first = a.word[0 .. std.mem.indexOfScalar(u8, a.word, ' ') orelse a.word.len]; + if (std.mem.eql(u8, typed, first)) return answer(p, i, a.key); + } + return false; +} + +/// A question's Diff: the disk's text read (the host's read, taped) and +/// set against the buffer's, the lines they share at either end left out; +/// where they part, its place, and up to `Said.max_detail` of the lines +/// there, the disk's `+` and then the buffer's `-`, its detail, shown. +fn diskDiff(p: *Pardes, s: *Said, id: usize) void { + const pane = p.panes[id].?; + const f = if (pane.file) |*file| file else return; + const disk = @import("fs.zig").read(p, f.path) catch |err| return pardes.Messages.reportError(p, .at(id), "Diff", err); + defer p.gpa.free(disk); + const mine = pardes.panes.File.fileText(f, p.scratch.allocator()) catch return; + var a = std.mem.splitScalar(u8, mine, '\n'); + var b = std.mem.splitScalar(u8, disk, '\n'); + var line: u32 = 1; + var ours: []const u8 = ""; + var theirs: []const u8 = ""; + while (true) : (line += 1) { + const x = a.next(); + const y = b.next(); + if (x == null and y == null) return; + if (x != null and y != null and std.mem.eql(u8, x.?, y.?)) continue; + ours = if (x) |l| mine[@intFromPtr(l.ptr) - @intFromPtr(mine.ptr) ..] else ""; + theirs = if (y) |l| disk[@intFromPtr(l.ptr) - @intFromPtr(disk.ptr) ..] else ""; + break; + } + // The lines both end with, left out. + var ours_end = ours.len; + var theirs_end = theirs.len; + while (ours_end > 0 and theirs_end > 0) { + const ol = std.mem.lastIndexOfScalar(u8, ours[0 .. ours_end - 1], '\n'); + const tl = std.mem.lastIndexOfScalar(u8, theirs[0 .. theirs_end - 1], '\n'); + const o_line = ours[if (ol) |nl| nl + 1 else 0..ours_end]; + const t_line = theirs[if (tl) |nl| nl + 1 else 0..theirs_end]; + if (!std.mem.eql(u8, o_line, t_line)) break; + ours_end = if (ol) |nl| nl + 1 else 0; + theirs_end = if (tl) |nl| nl + 1 else 0; + } + s.places[0] = .{ .line = line, .col = 1 }; + s.places[0].path.set(f.path); + s.places[0].text.set("the disk's differs here"); + s.places_len = 1; + s.detail_len = 0; + // The disk's first: it is what the answer shows. + for ([_]struct { []const u8, []const u8 }{ .{ "+", theirs[0..theirs_end] }, .{ "-", ours[0..ours_end] } }) |side| { + var rows = std.mem.splitScalar(u8, std.mem.trimEnd(u8, side[1], "\n"), '\n'); + while (rows.next()) |row| { + if (side[1].len == 0 or s.detail_len == Said.max_detail) break; + s.detail[s.detail_len] = .{}; + _ = s.detail[s.detail_len].print("{s}{s}", .{ side[0], row }); + s.detail_len += 1; + } + } + s.open = true; +} + /// The words the newest live message said of `pane` has, "" for none: /// what its band shows, and what a write that failed on it answers. pub fn saidBy(m: *const Messages, pane: *const Pane) []const u8 { @@ -1093,3 +1236,52 @@ test "a burst of the same message is one message, counted, and moves nothing on const row = noticeRow(p, 78, &buf); try std.testing.expect(std.mem.endsWith(u8, row.text[0..row.left], "3 files \u{d7}10")); } + +test "a file changed on disk under unsaved text asks in its tag and never takes the keyboard: SPC e's keyboard answers, d shows the disk's lines as ghosts, Esc leaves it waiting, B2 on Reload reads it again" { + const p = try Pardes.init(std.testing.allocator, .{ .cols = 120, .rows = 20 }); + defer p.deinit(); + var tmp = std.testing.tmpDir(.{}); + defer tmp.cleanup(); + try tmp.dir.writeFile(std.testing.io, .{ .sub_path = "c.zig", .data = "one\ntwo\nthree\n" }); + var dir: [4096]u8 = undefined; + const path = try std.fmt.allocPrint(std.testing.allocator, "{s}/c.zig", .{dir[0..try tmp.dir.realPath(std.testing.io, &dir)]}); + defer std.testing.allocator.free(path); + const pane = try p.setTestFile("one\ntwo\nthree\n"); + const id = p.view().active; + p.gpa.free(pane.file.?.path); + pane.file.?.path = try p.gpa.dupe(u8, path); + const f = &pane.file.?; + f.saved_hash = panes.File.fileHash(f); + // Unsaved: a line typed at the end. + for ([_]u21{ 'G', 'o', 'f', 'o', 'u', 'r', Key.escape }) |cp| p.update(.{ .key = .{ .cp = cp } }); + try std.testing.expect(f.revision != f.saved_revision); + const disk = "zero\none\ntwo\nthree\n"; + try tmp.dir.writeFile(std.testing.io, .{ .sub_path = "c.zig", .data = disk }); + p.update(.{ .file_changed = .{ .pane = .at(id), .bytes = disk } }); + const i = p.messages.waiting(pane) orelse return error.NotAsked; + try std.testing.expectEqual(Kind.question, p.messages.live[i].kind); + // In its tag at rest, its answers offered; its mark `?`. + const prefix = try pardes.tagline.tagPrefix(p, pane); + try std.testing.expect(std.mem.indexOf(u8, prefix, "changed on disk \u{25b8} r Reload k Keep mine d Diff \u{b7} SPC e to answer") != null); + try std.testing.expectEqualStrings("Reload", p.messages.waitingAnswers(pane)[0].word); + // The keyboard is not its: `r` is the body's (helix's replace). + p.update(.{ .key = .{ .cp = 'k' } }); + try std.testing.expect(p.messages.waiting(pane) != null); + // Given the keyboard: `d` shows the disk's lines and keeps asking; Esc + // leaves it waiting. + p.view().answering = pane.serial; + p.update(.{ .key = .{ .cp = 'd' } }); + const asked = &p.messages.live[p.messages.waiting(pane).?]; + try std.testing.expect(asked.open); + try std.testing.expectEqual(@as(u32, 1), asked.places[0].line); + try std.testing.expectEqualStrings("+zero", asked.detail[0].slice()); + try std.testing.expectEqual(pane.serial, p.view().answering); + p.update(.{ .key = .{ .cp = Key.escape } }); + try std.testing.expectEqual(@as(u32, 0), p.view().answering); + try std.testing.expect(p.messages.waiting(pane) != null); + // B2 on `Reload` in its tag: read again, the question gone. + try std.testing.expectEqual(@as(?usize, null), pardes.exec.execute(p, id, "Reload")); + while (p.nextEffect()) |_| {} + try std.testing.expect(p.messages.waiting(pane) == null); + try std.testing.expectEqualStrings(disk, p.panes[id].?.file.?.content); +} diff --git a/core/exec.zig b/core/exec.zig index 3bb6e809..6b05cb8e 100644 --- a/core/exec.zig +++ b/core/exec.zig @@ -633,6 +633,8 @@ const max_exec_depth = 8; /// child is `$SHELL -c` the line, which shows its output and `exit N` when /// done, and which Kill signals. Answers the pane it went to. pub fn execute(p: *Pardes, id: usize, txt: []const u8) ?usize { + // A question's answer word, on the pane it waits on (B2 on `Reload`). + if (pardes.Messages.answerWord(p, id, txt)) return null; return executeFrom(p, id, txt, false); } diff --git a/core/keys.zig b/core/keys.zig index 5257a093..68e3585d 100644 --- a/core/keys.zig +++ b/core/keys.zig @@ -206,6 +206,23 @@ pub fn handleKey(p: *Pardes, key: Key) void { } return; } + // A background question SPC e gave the keyboard: one of its answers' + // keys answers it (Diff leaves it asking), Esc leaves it waiting, and + // nothing else gets past it (pick-ui SPEC §10.4). + if (p.view().answering != 0) answering: { + const v = p.view(); + const at = p.paneBySerial(v.answering) orelse break :answering; + const i = p.messages.waiting(p.panes[at].?) orelse break :answering; + if (key.cp == Key.escape and !key.ctrl and !key.alt) { + v.answering = 0; + p.needs_frame = true; + return; + } + if (key.ctrl or key.alt or key.cp > 0x7f) return; + if (pardes.Messages.answer(p, i, @intCast(key.cp)) and key.cp != 'd') v.answering = 0; + return; + } + p.view().answering = 0; if (p.view().window_pick != null) return layout.windowKey(p, key); const pane = p.panes[p.view().active] orelse return; layout.noteTyped(p); diff --git a/core/ninep/ctl.zig b/core/ninep/ctl.zig index c7f22b9a..e47aec94 100644 --- a/core/ninep/ctl.zig +++ b/core/ninep/ctl.zig @@ -2388,7 +2388,9 @@ test "a file changed on disk under unsaved edits is not reloaded: it says so, ge pardes.panes.File.changed(p, 0, "three\n"); try testing.expectEqualStrings("two\nmine\n", f.content); try testing.expect(f.revision != f.saved_revision); - try testing.expect(th.logHas(p, "changed on disk (get reloads it, Save overwrites it)")); + // ...and asks, in its tag (Messages.waiting), which /log hears. + try testing.expect(p.messages.waiting(p.panes[0].?) != null); + try testing.expect(th.logHas(p, "changed on disk\n")); var want: [32]u8 = undefined; try testing.expect(th.logHas(p, try std.fmt.bufPrint(&want, "changed {d}\n", .{serial}))); // Exit and get still ask about the edits. diff --git a/core/tagline.zig b/core/tagline.zig index 02d1b277..a389bb6d 100644 --- a/core/tagline.zig +++ b/core/tagline.zig @@ -172,7 +172,12 @@ pub fn tagPrefix(p: *Pardes, pane: *Pane) ![]u8 { /// The prefix as the tag shows it, built in `arena`. pub fn prefixIn(p: *const Pardes, arena: std.mem.Allocator, pane: *Pane) ![]u8 { - const prefix = try pathPrefix(p, arena, pane); + const path = try pathPrefix(p, arena, pane); + // Asking (SPEC §3.2): a question waiting on it, after the path while + // the tag is at rest (not while it has the keyboard). + var asking: [512]u8 = undefined; + const asks = if (pane.focus == .tag or pane.prompt == .name) "" else p.messages.askingText(pane, p.view().answering == pane.serial, &asking); + const prefix = if (asks.len > 0) try std.mem.concat(arena, u8, &.{ path, " ", asks }) else path; // The space between the prefix and the tag's own text is the text's // (every default starts with one), but the prefix is computed, so it // cannot trust the text to keep it: with it deleted, Look and Exec diff --git a/test/monkey9p.zig b/test/monkey9p.zig index 1f213a3b..aaef1de6 100644 --- a/test/monkey9p.zig +++ b/test/monkey9p.zig @@ -1318,7 +1318,7 @@ fn oneFailureRule(c: *Ctx, a: Allocator, res: *Res) ?[]const u8 { // is the host's news, said whenever it arrives: no write's. var msgs: std.ArrayList([]const u8) = .empty; for (occurrences(a, window, "msg")) |m| { - if (std.mem.indexOf(u8, m, " deleted on disk (") != null or std.mem.indexOf(u8, m, " changed on disk (") != null or + if (std.mem.indexOf(u8, m, " deleted on disk (") != null or std.mem.indexOf(u8, m, " changed on disk") != null or std.mem.indexOf(u8, m, " reloaded ") != null) continue; msgs.append(a, m) catch oom(); } diff --git a/test/snapshots/filewatch.golden b/test/snapshots/filewatch.golden index 1e10ec08..b9716691 100644 --- a/test/snapshots/filewatch.golden +++ b/test/snapshots/filewatch.golden @@ -31,7 +31,8 @@ | | · @p1 a copy of the terminal's text: Tab or B2 runs it; what the program draws next replaces it (Ctrl-b types to the program) 1 message · SPC h m == snap kept grid=210x31 cursor=15,7 -|30: · /tmp/pardes-snap/filewatch/cwd/w.txt changed on disk (get reloads it, Save overwrites it) 2 messages · SPC h m +|6: ?/tmp/pardes-snap/filewatch/cwd/w.txt changed on disk ▸ r Reload k Keep mine d Diff · SPC e to answer Save Term Collapse Follow Del +|30: ? /tmp/pardes-snap/filewatch/cwd/w.txt changed on disk 1 question · SPC e == snap reloaded_sub grid=210x31 cursor=15,7 |19: 1 RENAMED |20: ~ @@ -42,4 +43,4 @@ |25: |26: |27: -|30: · reloaded /tmp/pardes-snap/filewatch/cwd/sub/s.txt 3 messages · SPC h m +|30: ? /tmp/pardes-snap/filewatch/cwd/w.txt changed on disk +1 · 1 question · SPC e -- cgit v1.3