From 3b5568952e9a2bd253e87153d68acd6914126fb6 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sat, 8 Feb 2025 23:12:11 +0800 Subject: [PATCH] fix(nvim-plug): fix default ui progress --- bundle/nvim-plug/lua/plug/installer.lua | 3 ++- bundle/nvim-plug/lua/plug/ui.lua | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/bundle/nvim-plug/lua/plug/installer.lua b/bundle/nvim-plug/lua/plug/installer.lua index 10986e08c..25779e807 100644 --- a/bundle/nvim-plug/lua/plug/installer.lua +++ b/bundle/nvim-plug/lua/plug/installer.lua @@ -17,13 +17,14 @@ local config = require('plug.config') local on_uidate --- @class PlugUiData ---- @field command? string clone/pull/build +--- @field command? string clone/pull/build/curl --- @filed clone_process? string --- @filed clone_done? boolean --- @filed building? boolean --- @filed build_done? boolean --- @field pull_done? boolean --- @field pull_process? string +--- @field curl_done? boolean if config.ui == 'default' then on_uidate = require('plug.ui').on_update diff --git a/bundle/nvim-plug/lua/plug/ui.lua b/bundle/nvim-plug/lua/plug/ui.lua index 17f971758..cb936e344 100644 --- a/bundle/nvim-plug/lua/plug/ui.lua +++ b/bundle/nvim-plug/lua/plug/ui.lua @@ -17,7 +17,7 @@ local plugin_status = {} local function count_done(p) done = 0 for _, v in pairs(p) do - if v.clone_done then + if v.command and v[v.command .. '_done'] then done = done + 1 end end