diff options
| author | Can Celik <ogulcancelik@gmail.com> | 2026-09-10 21:51:57 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-09-10 21:51:57 +0300 |
| commit | 425c86179791cd32e2d4ce0ae7f269940b4b0663 (patch) | |
| tree | e52c4383a6d69216cbe2a32638bf90841d7e2189 /vendor/libghostty-vt/src/cli/list_fonts.zig | |
| parent | 90e947a6e26e02f10ec7f1694c4eb5b78a86406b (diff) | |
chore: upgrade libghostty and preserve terminal behavior (#3906)
Diffstat (limited to 'vendor/libghostty-vt/src/cli/list_fonts.zig')
| -rw-r--r-- | vendor/libghostty-vt/src/cli/list_fonts.zig | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/vendor/libghostty-vt/src/cli/list_fonts.zig b/vendor/libghostty-vt/src/cli/list_fonts.zig index 6e08aa83..7cfce715 100644 --- a/vendor/libghostty-vt/src/cli/list_fonts.zig +++ b/vendor/libghostty-vt/src/cli/list_fonts.zig @@ -4,6 +4,7 @@ const ArenaAllocator = std.heap.ArenaAllocator; const Action = @import("ghostty.zig").Action; const args = @import("args.zig"); const font = @import("../font/main.zig"); +const global = @import("../global.zig"); const log = std.log.scoped(.list_fonts); @@ -60,7 +61,7 @@ pub const Options = struct { /// is identical to the `font-family` set of Ghostty configuration values, so /// this can be used to debug why your desired font may not be loading. pub fn run(alloc: Allocator) !u8 { - var iter = try args.argsIterator(alloc); + var iter = try args.argsIterator(alloc, global.args()); defer iter.deinit(); return try runArgs(alloc, &iter); } @@ -78,7 +79,7 @@ fn runArgs(alloc_gpa: Allocator, argsIter: anytype) !u8 { // Its possible to build Ghostty without font discovery! if (comptime font.Discover == void) { var buffer: [1024]u8 = undefined; - var stderr_writer = std.fs.File.stderr().writer(&buffer); + var stderr_writer = std.Io.File.stderr().writer(global.io(), &buffer); const stderr = &stderr_writer.interface; try stderr.print( \\Ghostty was built without a font discovery mechanism. This is a compile-time @@ -92,7 +93,7 @@ fn runArgs(alloc_gpa: Allocator, argsIter: anytype) !u8 { } var buffer: [2048]u8 = undefined; - var stdout_writer = std.fs.File.stdout().writer(&buffer); + var stdout_writer = std.Io.File.stdout().writer(global.io(), &buffer); const stdout = &stdout_writer.interface; // We'll be putting our fonts into a list categorized by family @@ -133,7 +134,7 @@ fn runArgs(alloc_gpa: Allocator, argsIter: anytype) !u8 { const gop = try map.getOrPut(family); if (!gop.found_existing) { try families.append(alloc, family); - gop.value_ptr.* = .{}; + gop.value_ptr.* = .empty; } try gop.value_ptr.append(alloc, full_name); } |
