You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
I was following the instructions to setup the doing status in the iTerm status bar, but it was difficult to get to work because one key detail was missing from the instructions. Basically, the status bar wasn't updating properly because the instructions where not clear, to me, on how to add `iterm2_set_user_var' to the prompt display.
In the instructions, it says:
Now we need a way to refresh the variable. I chose to do it with a prompt command,
running every time the prompt displays. Since all it’s going to do is cat a tiny
text file, there’s no performance hit. I suppose you could set up some kind of
polling, but this seems like the best solution.
These examples use functions created by the iTerm shell integration. If you haven’t
already, go to iTerm->Install Shell Integration to add the tools to your current shell.
In a fish_prompt function:
iterm2_set_user_var doingNow (command cat ~/.doing_cache)
Or in a bash prompt_command:
iterm2_set_user_var doingNow "$(command cat ~/.doing_cache)"
Unfortunately, for me, it was not immediately obvious how to add this to the prompt in a way that it would be properly triggered. Ultimately, here's what I found that I need to add, using bash:
I put this before the command where I invoke the prompt, i.e., PS1=... Once I did this, everything worked smoothly.
Describe the solution you'd like
I suggest/request/whatever-is-the-nicest-way-to-ask that you update your instructions to show explicitly how the iterm2_set_user_var is set in Bash through the use of the PROMPT_COMMAND syntax. (And maybe do the same for fish? I have no idea -- I have never used fish).
Additional context
Maybe this is related to issue #123?
Most importantly, thanks for this awesome tool!
The text was updated successfully, but these errors were encountered:
On further thought, I am going to close this. I may write my own blog post to share this tip and then link it back here, but I don't need to nor should be asking @ttscoff to do anything about this.
Is your feature request related to a problem? Please describe.
I was following the instructions to setup the doing status in the iTerm status bar, but it was difficult to get to work because one key detail was missing from the instructions. Basically, the status bar wasn't updating properly because the instructions where not clear, to me, on how to add `iterm2_set_user_var' to the prompt display.
In the instructions, it says:
Unfortunately, for me, it was not immediately obvious how to add this to the prompt in a way that it would be properly triggered. Ultimately, here's what I found that I need to add, using bash:
I put this before the command where I invoke the prompt, i.e.,
PS1=...Once I did this, everything worked smoothly.Describe the solution you'd like
I suggest/request/whatever-is-the-nicest-way-to-ask that you update your instructions to show explicitly how the
iterm2_set_user_varis set in Bash through the use of thePROMPT_COMMANDsyntax. (And maybe do the same for fish? I have no idea -- I have never used fish).Additional context
Maybe this is related to issue #123?
Most importantly, thanks for this awesome tool!
The text was updated successfully, but these errors were encountered: