Update cwd of the reedline instance every REPL loop

This commit is contained in:
YizhePKU 2024-06-01 04:05:22 +08:00
parent 3a593d1045
commit 73fe1829e7

View File

@ -392,6 +392,13 @@ fn loop_iteration(ctx: LoopContext) -> (bool, Stack, Reedline) {
.with_quick_completions(config.quick_completions)
.with_partial_completions(config.partial_completions)
.with_ansi_colors(config.use_ansi_coloring)
.with_cwd(
engine_state
.cwd(None)
.unwrap_or_default()
.to_string_lossy()
.to_string(),
)
.with_cursor_config(cursor_config);
perf(