From 12d75c0c26f7801699c20952eccce4ef5cf1084b Mon Sep 17 00:00:00 2001 From: Vaxry Date: Fri, 5 Apr 2024 03:00:34 +0100 Subject: [PATCH] hyprpm: ignore version checks for shallow clones --- hyprpm/src/core/PluginManager.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hyprpm/src/core/PluginManager.cpp b/hyprpm/src/core/PluginManager.cpp index 64b87379..0677fa39 100644 --- a/hyprpm/src/core/PluginManager.cpp +++ b/hyprpm/src/core/PluginManager.cpp @@ -226,7 +226,7 @@ bool CPluginManager::addNewPluginRepo(const std::string& url, const std::string& for (auto& p : pManifest->m_vPlugins) { std::string out; - if (p.since > HLVER.commits) { + if (p.since > HLVER.commits && HLVER.commits >= 1 /* for --depth 1 clones, we can't check this. */) { progress.printMessageAbove(std::string{Colors::RED} + "✖" + Colors::RESET + " Not building " + p.name + ": your Hyprland version is too old.\n"); p.failed = true; continue; @@ -599,7 +599,7 @@ bool CPluginManager::updatePlugins(bool forceUpdateAll) { for (auto& p : pManifest->m_vPlugins) { std::string out; - if (p.since > HLVER.commits) { + if (p.since > HLVER.commits && HLVER.commits >= 1 /* for --depth 1 clones, we can't check this. */) { progress.printMessageAbove(std::string{Colors::RED} + "✖" + Colors::RESET + " Not building " + p.name + ": your Hyprland version is too old.\n"); p.failed = true; continue;