How to flip the lines of a visual selection in vim?

后端 未结 4 1235
一生所求
一生所求 2021-02-18 18:38

I want to take a visual selection and flip it so that the first line of the selection is on the bottom. From:


The
wheels
go
round.


        
4条回答
  •  误落风尘
    2021-02-18 19:06

    According to :help 12.4 you can mark the first line with the mt, move to the last line you want reversed then use the command :'t+1,.g/^/m 't

提交回复
热议问题