summaryrefslogtreecommitdiff
path: root/src/dump.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/dump.zig')
-rw-r--r--src/dump.zig4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/dump.zig b/src/dump.zig
index 954a3270..446776d4 100644
--- a/src/dump.zig
+++ b/src/dump.zig
@@ -99,6 +99,9 @@ pub const PaneKind = enum {
pub const Terminal = struct {
cwd: []const u8 = "",
+ /// The shell it runs when not the configured one (`Tty bash`); empty,
+ /// the configured one, as in dumps from before.
+ shell: []const u8 = "",
/// The rendered scrollback and screen as plain text, one row per line.
stream: []const u8 = "",
stream_b64: []const u8 = "",
@@ -747,6 +750,7 @@ fn initDump(gpa: std.mem.Allocator, opts: Options, zon_bytes: []const u8, previo
const restored = try pardes.panes.Terminal.restore(p, src, revive);
p.installPane(i, restored);
try restored.setOwnedCwd(t.cwd);
+ if (t.shell.len > 0) restored.shell = try gpa.dupe(u8, t.shell);
if (std.mem.startsWith(u8, src.tag, "TTY ")) restored.body.mode = .tty;
if (revive) p.emit(.{ .spawn = .{ .pane = @intCast(i), .serial = restored.serial, .cwd = .from(t.cwd) } });
break :terminal restored;