How to run a vim script interactively from vim command line?

后端 未结 4 765
伪装坚强ぢ
伪装坚强ぢ 2021-02-14 05:32

Is there a way to run these scripts from the : commandline with a few keystrokes?

Over the last couple of months, I\'ve built a series of fi

4条回答
  •  借酒劲吻你
    2021-02-14 06:01

    You could use the command feature of vim. In your unit_test_cpp.vim file you would add something like this:

    command Utc call CreateUnitTests()
    

    Now when you type :Utc it will call your function. The only limitation is that your command must start with an uppercase letter.

提交回复
热议问题