删除到vim中当前括号内的结尾

Shi*_*dim 3 linux vim text-editor

说我正在编辑这个json

{
  "a": {"language": "python"},
  "b": {},
  "c": {"language": "java"},
  "d": {"encoding": "utf-16"}
}
Run Code Online (Sandbox Code Playgroud)

我的光标在b"b": {}.我想删除直到当前{}块结束 .所以它看起来像,

{
  "a": {"language": "python"},
  "
}
Run Code Online (Sandbox Code Playgroud)

看起来很奇怪.但解释我想要什么.

我怎么能在Vim中做到这一点?

Mar*_*rth 10

你可以用d]}.
来自:help ]}:

                                    *]}*
]}          go to [count] next unmatched '}'.
            |exclusive| motion.
Run Code Online (Sandbox Code Playgroud)

该帮助还说这是该动作的用例之一:

The above four commands can be used to go to the start or end of the current
code block.  It is like doing "%" on the '(', ')', '{' or '}' at the other
end of the code block, but you can do this from anywhere in the code block.
Run Code Online (Sandbox Code Playgroud)