fix(wrapper): don't let fish's alt-screen probe permanently hide the overlay (#141)
fixes #139 fish's own startup terminal probe was misread as a full screen app taking over, permanently suppressing suggestions
This commit is contained in:
@@ -317,8 +317,13 @@ func runWrapper() {
|
||||
})
|
||||
isExecuting := func() bool {
|
||||
if isAltScreenActive.Load() {
|
||||
pgrp, pgrpErr := unix.IoctlGetInt(int(ptmx.Fd()), unix.TIOCGPGRP)
|
||||
if pgrpErr == nil && pgrp == shellPGID {
|
||||
isAltScreenActive.Store(false)
|
||||
} else {
|
||||
return true
|
||||
}
|
||||
}
|
||||
if isCommandActive.Load() {
|
||||
// for bash: no preexec/precmd hooks, so fall back to TIOCGPGRP to detect when shell returns
|
||||
if shellName == "bash" {
|
||||
|
||||
Reference in New Issue
Block a user