summaryrefslogtreecommitdiff
path: root/src/ninep
diff options
context:
space:
mode:
Diffstat (limited to 'src/ninep')
-rw-r--r--src/ninep/ctl.zig10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/ninep/ctl.zig b/src/ninep/ctl.zig
index 8a84e37f..2cfee904 100644
--- a/src/ninep/ctl.zig
+++ b/src/ninep/ctl.zig
@@ -612,18 +612,18 @@ const e_prompt = "control message needs its argument";
/// is /status's or the DumpConfig window's.
fn writeSettings(p: *Pardes, w: *std.Io.Writer) !void {
try writeSettingsFor(p, &p.settings, w, builtins.viewCapabilities(p));
- try w.writeAll("LocationsConfig ");
- try p.locations_config.write(w);
- try w.writeByte('\n');
- if (comptime builtins.Pet.enabled) if (builtins.registry.here(p, .Pet)) try w.print("Pet {s}\n", .{@tagName(p.settings.pet)});
}
/// The setting words of `s`, one a line, those a frontend of `caps` takes
-/// (the root ctl's: the live view's).
+/// (the root ctl's: the live view's), and the session's LocationsConfig.
fn writeSettingsFor(p: *Pardes, s: *const config.Runtime, w: *std.Io.Writer, caps: config.Runtime.Capabilities) !void {
// DumpConfig's words: a `# Word unsupported` comment for what `caps` lacks.
var dump_dir: [1024]u8 = undefined;
+ var located_buf: [256]u8 = undefined;
+ var located: std.Io.Writer = .fixed(&located_buf);
+ try p.locations_config.write(&located);
try config.Runtime.writeSettings(w, .{
+ .locations = located.buffered(),
.theme_name = p.theme().name,
.theme_file = pardes.colors.loadedThemeFile(p),
.compiled_default_shell = config.defaultShell(),