Since upgrade to Emacs 28.1, I have noted an annoy change in shell-script mode auto-formatting.
I would like to recover the old behavior
Before, if I entered
if [ "$x" = "" ];then
export x=$y
fi
and then enter new line, the new line would align with the fi
if [ "$x" = "" ];then
export x=$y
fi
cp fred ethel
Now it I do the same thing I get the new line indented
if [ "$x" = "" ];then
export x=$y
fi
cp fred ethel
The matching code also does not recognize that the fi is connected to the then statement.
This is not the case if I break the if into two lines:
if [ "$x" = "" ]
then
export x=$y
fi
cp fred ethel
Any suggestions?
emacs -Q
then consider filing a bug report:M-x report-emacs-bug
. It might represent an intentional change, but it might not. A bug report will be responded to with the answer.