diff options
Diffstat (limited to 'src/look.zig')
| -rw-r--r-- | src/look.zig | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/look.zig b/src/look.zig index 65d001a9..36eae75c 100644 --- a/src/look.zig +++ b/src/look.zig @@ -583,8 +583,9 @@ pub fn runSearch(p: *Pardes, id: usize, pat_raw: []const u8, kind: Search, start if (pat.len == 0) return 0; const arena = p.scratch.allocator(); // where the pane lives: a file's directory, a shell's cwd — the walk - // root, and the directory the results buffer is named in. - const dir = Pardes.paneDir(pane); + // root, and the directory the results buffer is named in. From a + // column's or the workspace's tag, the session's. + const dir = if (p.exec_header) p.sessionDir() else Pardes.paneDir(pane); const out = try arena.alloc(u8, filesystem.search_max_output_bytes); var out_len: usize = 0; var nrows: usize = 0; |
