refactor(refactor): use higher local apis and some cleanup

This commit is contained in:
Steven Sojka 2020-06-29 09:58:51 -05:00 committed by Kiyan Yazdani
parent 6f8e4c97a4
commit d73500eaa6
10 changed files with 103 additions and 69 deletions

View file

@ -45,7 +45,7 @@ function M.get_cache_dir()
return nil, 'Invalid cache rights, $XDG_CACHE_HOME or /tmp should be read/write'
end
--- Gets a property at path
-- Gets a property at path
-- @param tbl the table to access
-- @param path the '.' seperated path
-- @returns the value at path or nil
@ -62,4 +62,10 @@ function M.get_at_path(tbl, path)
return result
end
-- Prints a warning message
-- @param text the text message
function M.print_warning(text)
api.nvim_command(string.format([[echohl WarningMsg | echo "%s" | echohl None]], text))
end
return M