-
Notifications
You must be signed in to change notification settings - Fork 423
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
iTerm2 LP_ENABLE_TITLE not escaping properly #581
Comments
Note that liquidprompt version 1.11 is very out of date, and reported issues are only supported on the latest version. However, I am also seeing this issue. I'm on iTerm2 v3.3.1 and latest liquidprompt (eda83ef). I have a mostly stock liquidpromptrc, and I can't see anything obvious that would cause this. I'll keep digging. |
I no longer have access to a Mac to test/develop a fix for this. I still want this to make v2.0, but I'll need help. |
I've got a Mac and am happy to test and even develop/bug fix. I've stopped using liquidprompt right now though, so which version should I download to test this? Has any fix been attempted or am I going to be testing if the bug is still around? |
Thanks for being willing to help even if you don't use it. Version v1.12.0 is our latest stable, you should test with that. I think a few things got changed around terminal titles, but I don't really expect the issue to be gone. I do plan on doing some work on the default terminal title, but I would want to know what is causing this issue so we can avoid the problem for the future implementation. |
Sure, not a problem. I'm not using it now, but have used your code for
years, and who knows, may use it again someday.
|
I'm seeing that in my iTerm2 title.
Steps that I've taken to test:
I was using the |
Perfect. Could you run And if you wouldn't mind doing the same thing (with clean rc files) for Bash, just so we can rule out shell issues. |
Do you know how I can start bash with clean rc files? It'll save me some
time from needing to Google. I luckily already new the options to pass into
zsh to start with clean rc files.
…On Sun, 8 Nov, 2020, 18:29 Mark Vander Stel, ***@***.***> wrote:
Perfect. Could you run printf '%q\n' "$PS1" and post the output?
And if you wouldn't mind doing the same thing (with clean rc files) for
Bash, just so we can rule out shell issues.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#581 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAPMQS3LTQSBL76CXNRH4OLSO2I4RANCNFSM4ILDVWCQ>
.
|
If it's inheriting from the parent shell, try |
Steps followed
Result |
Hm, unlikely. We have checks to not load if not in an interactive terminal. Probably loading bash like that is not loading any env vars at all. Try Also Liquidprompt will still load its config, so of you have title disabled in the config, that export before loading Liquidprompt won't do anything. It would only do something if you don't have |
Glad to see that, should make debugging easier. Can you post the output of |
Output of printf '%q\n' "$PS1"Bash
zsh
|
Break it down: Oh, yeah, that's obvious. Both have a So why does the title have that character, but the main prompt doesn't? My only guess is that this line: Coincidentally I've been working on a way to replace control chars in the prompt with #632. I'm not sure if that would help here since 1) this doesn't seem to be originating from a data function and 2) it is in the title, but not the main prompt. What I need from youCould you test this command in Bash for me? Are you using a custom What version of Liquidprompt are you running now? |
For all the tests that I ran, I'd pinned the version to
This could very well be the culprit. Since this was testing, I'd created new profiles for it in iTerm, but, these profiles didn't have any PATH setup, so the sed that would have been invoked would have been MacOS's sed. Since for work I need compatibility between Mac and Linux, I use the GNU binary for sed from Homebrew.
And I'll also give you the output to this in bash. |
No, that is the latest stable, so perfect. I just wanted to make sure since you aren't actively using Liquidprompt you weren't on an older version. |
Output
|
Thanks @kapad, you have been very helpful tracking this down. It turns out that All of our other uses of While working on v2.0, I redesigned some of the title internals, which actually accidentally fixed this problem. I'm hesitant to fix this in a v1.12.2, as it's already fixed in v2.0 (which is hopefully getting close to release), and I don't see any way to fix it before v2.0 without adding another subshell, adding extra runtime for all users. I'll mark this as will be fixed by v2.0, and update this issue when that happens. |
As I mentioned before, I accidentally fixed this. It is now fixed in v2.0.0-beta.1. However, if you are using a custom |
I'm using iTerm2 and when I set
LP_ENABLE_TITLE=1
but the title doesn't seem to be escaped correctly, and I see??
at the end for every terminal.What would be the correct settings for
LP_TITLE_OPEN
andLP_TITLE_CLOSE
to fix this?Shell: bash
Operating system: macOS Mojave
Liquid Prompt version (tag, commit): 1.11 2016-06-25 (Installed from Homebrew).
The text was updated successfully, but these errors were encountered: