Skip to content
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

[Ghostty] Bad left prompt with shell integration enabled #543

Open
SuperDuperDeou opened this issue Dec 27, 2024 · 2 comments
Open

[Ghostty] Bad left prompt with shell integration enabled #543

SuperDuperDeou opened this issue Dec 27, 2024 · 2 comments
Labels
compatibility question Question / Mis-usage

Comments

@SuperDuperDeou
Copy link

SuperDuperDeou commented Dec 27, 2024

$ ble summary
GNU bash, version 5.2.37(1)-release (x86_64-pc-linux-gnu) [Artix Linux]
ble.sh, version 0.4.0-devel4+17646524 (noarch) [git 2.47.1, GNU Make 4.4.1, GNU Awk 5.3.1, API 4.0, PMA Avon 8-g1, (GNU MPFR 4.2.1, GNU MP 6.3.0)]
bash-completion, version 2.15.0 (hash:480ffcc6a751e55621ec526eb5dea7a0d86d9e72, 17877 bytes) (noarch)
fzf key-bindings, (hash:2da32cbab672fc962b4c56c6a052a6bf47ef2c12, 5618 bytes) (noarch) �[1m(integration: on)
fzf completion, (hash:afdb947635ba13e3f5a5f6d147f943e43f7dbbf3, 17559 bytes) (noarch) �[1m(integration: on)
bash-preexec, (hash:14a677888d35643b5ade7558b75ecc25746ac05b, 14704 bytes) (noarch)
locale: LANG=it_IT.utf8
terminal: TERM=xterm-ghostty wcwidth=15.0-west/16.0-2+ri, xterm:10 (1;10;0)
options: -emacs +vi +extglob +histappend -hostcomplete +inherit_errexit

While using Ghostty with shell integration enabled, after I run the first command, the left prompt becomes [ble: press RET to continue]. Right prompt and status bar are fine.

I actually have no idea if this issue is from Ghostty or from Blesh, but you gotta start from somewhere.

@akinomyoga
Copy link
Owner

akinomyoga commented Dec 27, 2024

The Ghostty shell integration seems to replace the bashrc file with its own shell integration script and tries to manually source ~/.bashrc from the shell integration script. After that, it seems to try to introduce non-trivial shell setups such as bash-preexec.sh.

How do you load ble.sh in your ~/.bashrc? Do you have --attach=none and ble-attach? Or do you simply source ble.sh without ble-attach? If you use the former setup with ble-attach, it wouldn't work because ble-attach needs to be performed at the end of the shell startup file, while the Ghostty shell integration tries to execute something non-trivial after sourcing ~/.bashrc. Could you try simply sourcing ble.sh without using ble-attach and see if the behavior changes?

@SuperDuperDeou
Copy link
Author

I was in fact using ble-attach.

Just sourcing ble.sh does not result in the bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compatibility question Question / Mis-usage
Projects
None yet
Development

No branches or pull requests

2 participants