From 2ca2813207403ca8e9ffe75e8bb96945df2b1bd0 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Tue, 29 Sep 2026 05:25:34 -0300 Subject: The boot scratch is /+New, not /+New At boot the scratch under the shell was made before the shell said where it was, so its name was /+New. A scratch made from a pane with no directory yet is now the session's, /+New. Co-Authored-By: Claude Opus 5.5 --- src/pardes.zig | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/pardes.zig') diff --git a/src/pardes.zig b/src/pardes.zig index 7e426ba4..59e8670f 100644 --- a/src/pardes.zig +++ b/src/pardes.zig @@ -4850,7 +4850,10 @@ pub const Pardes = struct { const src = p.panes[from_id] orelse return error.MissingPane; const content = try p.gpa.dupe(u8, ""); errdefer p.gpa.free(content); - const np = try panes.Output.open(p, free, paneDir(src), .{ .cmd = .New }, "", content); + // A terminal that has not said where it is yet (the boot layout's) + // has no directory: the scratch is the session's, /+New. + const dir = paneDir(src); + const np = try panes.Output.open(p, free, if (dir.len == 0) p.sessionDir() else dir, .{ .cmd = .New }, "", content); np.cwd = .{ .inherited = src }; np.body.cur_pinned = true; return np; -- cgit v1.3