style: autoformat all the things

Namely: applied stylua to the whole repo and ran marksman on README.md.
This commit is contained in:
Oula Kuuva
2023-03-21 08:57:03 +02:00
committed by okuuva
parent 14bc188b5e
commit 343bbfa98a
7 changed files with 291 additions and 291 deletions
+19 -19
View File
@@ -1,25 +1,25 @@
local TITLE = "auto-save"
return function(msg, kind)
local has_notify_plugin = pcall(require, "notify")
local level = {}
local has_notify_plugin = pcall(require, "notify")
local level = {}
if kind == "error" then
level.log = vim.log.levels.ERROR
level.type = "error"
elseif kind == "warn" then
level.log = vim.log.levels.WARN
level.type = "error"
else
level.log = kind or vim.log.levels.INFO
level.type = "info"
end
if kind == "error" then
level.log = vim.log.levels.ERROR
level.type = "error"
elseif kind == "warn" then
level.log = vim.log.levels.WARN
level.type = "error"
else
level.log = kind or vim.log.levels.INFO
level.type = "info"
end
if has_notify_plugin then
vim.notify(msg, level.log, {
title = TITLE,
})
else
vim.notify(("%s: %s"):format(TITLE, msg), level.log)
end
if has_notify_plugin then
vim.notify(msg, level.log, {
title = TITLE,
})
else
vim.notify(("%s: %s"):format(TITLE, msg), level.log)
end
end