diff --git a/openhands/runtime/utils/bash.py b/openhands/runtime/utils/bash.py index 9103baf53e0e..929574e0025a 100644 --- a/openhands/runtime/utils/bash.py +++ b/openhands/runtime/utils/bash.py @@ -39,7 +39,9 @@ def __init__(self, work_dir: str, username: str | None = None): self.pane = self.session.attached_window.attached_pane # Configure bash to use simple PS1 and disable PS2 - self.pane.send_keys(f'export PS1="{self.PS1}"; export PS2=""') + self.pane.send_keys( + f'export PROMPT_COMMAND=\'export PS1="{self.PS1}"\'; export PS2=""' + ) time.sleep(0.2) # Wait for command to take effect self._clear_screen()