1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-27 12:41:15 +02:00

refactor: repl prompts are now the job of the interacter

This commit is contained in:
Jade Lovelace 2024-02-26 00:43:44 -08:00
parent 70a6ce139b
commit ea31b8a117
3 changed files with 18 additions and 7 deletions

View file

@ -195,7 +195,7 @@ ReplExitStatus NixRepl::mainLoop()
logger->pause();
// When continuing input from previous lines, don't print a prompt, just align to the same
// number of chars as the prompt.
if (!interacter->getLine(input, input.empty() ? "nix-repl> " : " ")) {
if (!interacter->getLine(input, input.empty() ? ReplPromptType::ReplPrompt : ReplPromptType::ContinuationPrompt)) {
// Ctrl-D should exit the debugger.
state->debugStop = false;
logger->cout("");