Add autoloaded echomsg utility functions

* `echo#warning({message})` sets `echohl WarningMsg` and echos the message
* `echo#error({message})` sets `echohl ErrorMsg` and echos the message
This commit is contained in:
Kenneth Benzie 2021-01-06 00:21:37 +00:00
parent a0df92852a
commit c94bc3ba90

11
autoload/echo.vim Normal file
View File

@ -0,0 +1,11 @@
function! echo#warning(message) abort
echohl WarningMsg
echomsg a:message
echohl None
endfunction
function! echo#error(message) abort
echohl ErrorMsg
echomsg a:message
echohl None
endfunction