How to execute the contents of a buffer?

前端 未结 2 565
南旧
南旧 2020-12-25 11:41

I have a vim script I\'m developing in my current buffer and I want to execute it. Is there a simple way to do it?

After a long search I have only found two related

2条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-25 11:58

    An autocmd to source the file whenever you save might help:

    autocmd BufWritePost  source %
    

提交回复
热议问题