How to select the currently indented lines in VIM

4

How I can selected the lines with the same indent?

For example:

if true: 
    line 1
    line 2
    ...
    line n

If the cursor is over line 2, how I can selected from line 1 to line n?

juanpablo

Posted 2012-01-28T22:36:54.797

Reputation: 5 216

Answers

4

Take a look at vim-indent-object.

Rob Wouters

Posted 2012-01-28T22:36:54.797

Reputation: 356

amazing! with this I can sort attributes in CSS, in normal mode vii:!sort :) – juanpablo – 2012-01-29T20:46:48.417