Outdent with tabs on line ends deletes chars


#1

Hello,

while i was rearranging some config files, i noticed that outdent crushes the first chars at the line beginning if there are accidental tabs somewhere else in that line.

So if you don’t stop outdenting at the start of test1 it will crush the chars and the tab until the start of test2:

	test1 	test2

Shift-tab eats characters
#2

I’m not sure I understand what you’re saying. Can you give more exact repro steps, including what you expect to see and what you actually see?


#3

Here some pictures:

I also tried to reproduce in a plain file - with no success. It seems that its caused by the source of the file. I scp’ed them from a Ubuntu 12.04 Server. If i copy and paste the contend into a new file - it doesn’t happened.

Here some output about the encoding:

Original File (as shown above):

mf-nowak-mac:nginxConfig2014 fabiannowak$ file -I live_443 
live_443: text/plain; charset=us-ascii

New File with copied contents:

mf-nowak-mac:nginxConfig2014 fabiannowak$ file -I neu
neu: text/x-c++; charset=us-ascii

#4

Another example to show the behavior:

I only pressed shift-tab continuously to outdent completely. Line 31 has a tab between “deleted” and “this not”. As i go on to outdent it deletes everything until “this not”.


#5

Ok, this is much more clear. Thanks!


#6

I also could reproduce this using the vi (on my macbook) for file creation and editing with atom.
Also using cat to redirect the content into a new file, transfers the behavior of the outdent.

If i create the file with atom and than redirect the content, i don’t have the outdent problem.