You are not logged in.

#1 2021-08-12 11:16:09

ottoshmidt
Member
From: Tbilisi, Georgia
Registered: 2010-04-03
Posts: 30

Midnight Commander subshell cursor problems after recent upgrade

Hi MC users,

After a recent upgrade when pressing Ctrl-o in mc to switch to full shell view the cursor ends up on unpredictable locations each time. It's almost never aligned to the prompt. One has to press Enter for it to normalize. Also, in MC window a prompt in a subshell disappeared.

I tried downgrading mc, vte3, ncurses, tilda, fish shell, but the same. It happens both with fish shell and bash.
I use xfce4 but the same thing persists in non-gui ttys, too.

I haven't gone as far as downgrading mesa, x.org, etc., though.

Last edited by ottoshmidt (2021-08-12 19:03:53)

Offline

#2 2021-08-12 13:39:34

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 74,325

Re: Midnight Commander subshell cursor problems after recent upgrade

Likely your PS1?

read pcomm < /proc/$PPID/comm
if [ "$pcomm" = "mc" ]; then
    export PS1=somesimplestuff
else
    export PS1=somefancystuff
fi

Not sure about fish syntax.

Offline

#3 2021-08-12 19:55:25

ottoshmidt
Member
From: Tbilisi, Georgia
Registered: 2010-04-03
Posts: 30

Re: Midnight Commander subshell cursor problems after recent upgrade

seth wrote:

Likely your PS1?

read pcomm < /proc/$PPID/comm
if [ "$pcomm" = "mc" ]; then
    export PS1=somesimplestuff
else
    export PS1=somefancystuff
fi

Not sure about fish syntax.

Your hint helped me, thanks. So, fish shell had a regression in the latest update: https://github.com/fish-shell/fish-shell/issues/8091 (Which turns out is an MC problem).

Btw, in fish they don't have PS1 but a function fish_prompt that prints prompt.

Solution:
I downgraded fish to v3.2.2 until mc 4.8.27 comes out.

Last edited by ottoshmidt (2021-08-12 20:30:41)

Offline

Board footer

Powered by FluxBB