so I've been learning vim the past few weeks and am having trouble with defining functions and the such.
e.g. every time I define I function in python I write:
typing in insert mode: def foo<cursor>
open parenthesis: def foo(<cursor>)
- note that a closing parenthesis will be added automatically
add arguments: def foo(arg1, arg2<cursor>)
then I would have to <ESC>
, l
, a
to go into normal mode, move outside the closing paren, then append to add text, namely the colon and function definition.
Is there a faster way to do this? This process seems so tedious to me.
)
to go past the closing character just after the cursor. Some even provide unique mappings to go past several closing pairs at once. – Luc Hermitte May 18 '20 at 0:16