From 6f9132c3b20a2f42882c99370556901ff75afdc3 Mon Sep 17 00:00:00 2001 From: CJ van den Berg Date: Fri, 13 Feb 2026 23:01:15 +0100 Subject: [PATCH] fix: expand_home when detecting file paths in selection --- src/tui/tui.zig | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/tui/tui.zig b/src/tui/tui.zig index 30c70c9..9396713 100644 --- a/src/tui/tui.zig +++ b/src/tui/tui.zig @@ -1570,7 +1570,10 @@ const cmds = struct { pub fn open_file(self: *Self, ctx: Ctx) Result { if (get_active_selection(self.allocator)) |text| { defer self.allocator.free(text); - const link = try file_link.parse(text); + var buf: std.ArrayList(u8) = .empty; + defer buf.deinit(self.allocator); + const file_path = project_manager.expand_home(self.allocator, &buf, text); + const link = try file_link.parse(file_path); switch (link) { .file => |file| if (file.exists) return file_link.navigate(tp.self_pid(), &link),