开发者

Why doesn't the vim command viB work in ruby?

I would like to select the inner contents of a do/def..end block

def foo
    bar
end

e.g. bar would be selected开发者_StackOverflow above when hitting viB in the same way bar would be selected below in C:

void foo() {
    bar;
}

I know it probably only works for curly braces, but is there a way to make it work for do/end?


If you tend to leave empty spaces before and after your definitions (like I do) then you can use vip which highlights a paragraph.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜