From 0ff1fc99eb870f8a1e714a71c1a853066737c822 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Wed, 4 Nov 2026 20:54:21 -0300 Subject: rename: the terminal frontend is the tui (-Dplatform=tui, src/tui/tui.zig, --tui with --tty kept as its old spelling, the process tests' backend .tui and --backend=tui, docs/typ/builtins-tui.json, the Settings report's platform), and the builtin Tty is Term (its registry entry, SPC n t, every default tag, the docs, tests and snap scripts), Tty still run as Term through exec.acme_words, Tty+fish too on a tag and a ctl; tty as a pane's raw mode and as the OS's terminal unchanged Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge --- test/process/terminals.zig | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'test/process/terminals.zig') diff --git a/test/process/terminals.zig b/test/process/terminals.zig index e7e93a4f..96804adf 100644 --- a/test/process/terminals.zig +++ b/test/process/terminals.zig @@ -79,9 +79,9 @@ const Other = struct { }; fn runFile(gpa: std.mem.Allocator, exe: [:0]const u8) !void { - // shortcut: on the window a fresh Tty's first pty/run sometimes never - // answers (4 runs of 6); tty alone until that is found (docs/next-tests.md). - try process.only(.tty); + // shortcut: on the window a fresh Term's first pty/run sometimes never + // answers (4 runs of 6); tui alone until that is found (docs/next-tests.md). + try process.only(.tui); var d = try process.Detached.start(gpa, exe, "run", .{}); defer d.deinit(); const f = &d.files; @@ -97,12 +97,12 @@ fn runFile(gpa: std.mem.Allocator, exe: [:0]const u8) !void { try c.write(f.at("/pane/{d}/name", .{peer}), "/n/nosuchpeer/d/f.txt\n"); const count = std.mem.count(u8, try c.read(a, "/index"), "\n"); try refusedSaying(c, f.at("/pane/{d}/exec", .{peer}), "ls\n", "no such directory"); - try refusedSaying(c, f.at("/pane/{d}/exec", .{peer}), "Tty\n", "no such directory"); + try refusedSaying(c, f.at("/pane/{d}/exec", .{peer}), "Term\n", "no such directory"); try expectEqual(count, std.mem.count(u8, try c.read(a, "/index"), "\n")); try expect(!has(try c.read(a, "/log"), "exit 127")); try c.remove(f.at("/pane/{d}", .{peer})); try c.write("/exec", "Shell bash\n"); - try c.write("/exec", "Tty\n"); + try c.write("/exec", "Term\n"); var term: u32 = 0; var rows = std.mem.tokenizeScalar(u8, try c.read(a, "/index"), '\n'); while (rows.next()) |r| { @@ -222,8 +222,8 @@ fn namedOnce(gpa: std.mem.Allocator, exe: [:0]const u8) !void { var made: std.ArrayList(u32) = .empty; try made.append(a, try c.look(a, f.at("{s}/sub", .{root}), null)); const before = try serials(a, c); - try c.write("/pane/1/ctl", "Tty\n"); - if (shell(a, "command -v fish >/dev/null", .{}) == 0) try c.write("/pane/1/ctl", "Tty fish\n"); + try c.write("/pane/1/ctl", "Term\n"); + if (shell(a, "command -v fish >/dev/null", .{}) == 0) try c.write("/pane/1/ctl", "Term fish\n"); for (try serials(a, c)) |s| if (std.mem.indexOfScalar(u32, before, s) == null) try made.append(a, s); try expect(made.items.len >= 2); process.sleep(1500); // their shells start and say where they are @@ -235,14 +235,14 @@ fn namedOnce(gpa: std.mem.Allocator, exe: [:0]const u8) !void { try expect(!has(log, f.at("\nrename {d} ", .{s}))); try expect(has(log, f.at("\nnew {d} {s}", .{ s, root }))); } - // A shell that cannot start (its interpreter is not there): Tty fails + // A shell that cannot start (its interpreter is not there): Term fails // the write with why and leaves no pane; pty/ctl exec fails with why // and keeps its terminal. try d.put("badsh", "#!/nonexistent/interp\n"); const bad = f.at("{s}/badsh", .{root}); _ = libc.chmod(try std.fmt.allocPrintSentinel(a, "{s}", .{bad}, 0), 0o755); const panes = std.mem.count(u8, try c.read(a, "/index"), "\n"); - try refusedSaying(c, "/pane/1/ctl", f.at("Tty {s}\n", .{bad}), "interpreter /nonexistent/interp not found"); + try refusedSaying(c, "/pane/1/ctl", f.at("Term {s}\n", .{bad}), "interpreter /nonexistent/interp not found"); try refusedSaying(c, "/ctl", f.at("Shell {s}\n", .{bad}), "interpreter /nonexistent/interp not found"); process.sleep(300); try expectEqual(panes, std.mem.count(u8, try c.read(a, "/index"), "\n")); @@ -275,7 +275,7 @@ fn drive(gpa: std.mem.Allocator, exe: [:0]const u8, script: []const u8, key: ?u8 const f = &d.files; try d.put("command.sh", f.at("exec /bin/sh -c '{s}'\n", .{script})); try f.write("/ctl", "Shell /bin/sh\n"); - try f.write("/exec", "Tty\n"); + try f.write("/exec", "Term\n"); const term = try f.focused(); const body = f.at("/pane/{d}/body", .{term}); const data = f.at("/pane/{d}/pty/data", .{term}); -- cgit v1.3