[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#9193: 23.3; newline-and-indent broken in shell-script (sh mode)
From: |
Stefan Monnier |
Subject: |
bug#9193: 23.3; newline-and-indent broken in shell-script (sh mode) |
Date: |
Tue, 02 Aug 2011 21:46:53 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) |
> #! /bin/sh
> if [ $a == $b ]
> then
> echo newline-and-indent is OK here
> echo "newline-and-indent is NOT OK here"
> fi
> Now, put the cursor at the end of the first "echo" line and type ^J
> (bound to newline-and-indent). As expected, it does a
> newline-and-indent. Now put the cursor at the end of the second "echo"
> line and type ^J. It does the newline, but not the indent.
> [ Other possibly completely irrelevant information:
> Playing around a bit, I found that if I create my own function and
> instead of using (newline-and-indent) I use
> (newline)
> (sit-for .001)
> (indent-according-to-mode)
> then calling that function Does The Right Thing.
> ]
FWIW it seems to be fixed in the trunk (i.e. in the upcoming Emacs-24).
Could you try it out to confirm it fixes your problems?
Stefan
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- bug#9193: 23.3; newline-and-indent broken in shell-script (sh mode),
Stefan Monnier <=