Skip to content

Commit

Permalink
feat(ui): added statusline component to show pending updates
Browse files Browse the repository at this point in the history
  • Loading branch information
folke committed Dec 5, 2022
1 parent 65cd28e commit 315be83
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions lua/lazy/status.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
local Config = require("lazy.core.config")

local M = {}

function M.updates()
local Checker = require("lazy.manage.checker")
local updates = #Checker.updated
return updates > 0 and (Config.options.ui.icons.plugin .. "" .. updates)
end

function M.has_updates()
local Checker = require("lazy.manage.checker")
return #Checker.updated > 0
end

return M

0 comments on commit 315be83

Please sign in to comment.