1

I have been working to change my statusline in bash from powerline-shell to the powerline bindings for bash.

It appeared like it worked but when I opened tmux, after every command I get the error:

_update_ps1: command not found

I'm pretty sure that this is something left over from powerline-shell, but I cannot figure out where it's getting called. I don't see anything in my .bashrc or .tmux.conf files that are calling it (my tmux file is at this gist).

System: Ubuntu 20.04

Edit: Thanks to a pointer from a friend, I've identified the problem. tmux starts with the environment variable PROMPT_COMMAND set to _powerline_status_wrapper _powerline_set_prompt history -a; history -c; history -r; _update_ps1; history -a; history -c; history -r; _powerline_status_wrapper _powerline_tmux_set_pwd. I can change it manually every time I open a new window, but I don't know where or why it's getting set.

  • To start with, which version of Linux have you installed (Ubuntu server, Ubuntu desktop, Kubuntu, Lubuntu, Xubuntu, Ubuntu MATE, Mint, et al.) , and which release number? Different releases have different tools for us to recommend. Please click edit and add that vital information to your question so all the facts we need are in the question. Please don't use Add Comment, since that's our channel to you. All facts about your system should go in the Question with edit – K7AAY May 15 at 17:33
  • IIRC tmux starts a login shell by default - so look in all those places (~/.bash_profile, ~/.profile, /etc/profile, files in /etc/profile.d) as well – steeldriver May 15 at 18:39
  • I don't know exactly what I'm looking for, but I looked around in all of those and none of them are calling __update_ps1. What could be called in tmux after every command that wouldn't be called in bash? That's what's strange to me is that it's only appearing in tmux. – Jeremy May 17 at 1:04
  • Thanks to a pointer from a friend, I've identified the problem. tmux starts with the environment variable PROMPT_COMMAND set to _powerline_status_wrapper _powerline_set_prompt history -a; history -c; history -r; _update_ps1; history -a; history -c; history -r; _powerline_status_wrapper _powerline_tmux_set_pwd – Jeremy May 21 at 22:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.