mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-16 00:36:07 +03:00
use keybind struct's built-in capabity to format itself in +list-keybinds action
This commit is contained in:

committed by
Mitchell Hashimoto

parent
73a30ccd82
commit
863c3933d3
@ -46,12 +46,7 @@ pub fn run(alloc: Allocator) !u8 {
|
||||
defer config.deinit();
|
||||
|
||||
const stdout = std.io.getStdOut().writer();
|
||||
var iter = config.keybind.set.bindings.iterator();
|
||||
while (iter.next()) |next| {
|
||||
const keys = next.key_ptr.*;
|
||||
const value = next.value_ptr.*;
|
||||
try stdout.print("{}={}\n", .{ keys, value });
|
||||
}
|
||||
try config.keybind.formatConfig(stdout, "keybind=");
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user