bash 如何删除“__bp_precmd_invoke_cmd”错误?

mnt*_*123 8 bash .bash-profile

bash: __bp_precmd_invoke_cmd: command not found即使在命令成功执行后,我在每个命令之后也会出现错误。

例如,如果我运行该ls命令,我会在列表后得到正确的目录列表,但会收到以下错误消息

bash: __bp_precmd_invoke_cmd: command not found
bash: __bp_interactive_mode: command not found
Run Code Online (Sandbox Code Playgroud)

所有其他命令都一样,命令运行得很好,但我总是在每个命令之后收到上面提到的错误。

如何摆脱它?我试过谷歌但无法解决它。

小智 11

使用 nano 或 vim 等编辑器,添加行

unset PROMPT_COMMAND
Run Code Online (Sandbox Code Playgroud)

到您的.bashrc文件,它将在下一个会话中生效。

要在当前 shell 会话的生命周期内立即应用更改,请键入

unset PROMPT_COMMAND 
Run Code Online (Sandbox Code Playgroud)

在您的终端窗口中。