From 8c64a4bad710fb18e9b84812bd680a89d1e93661 Mon Sep 17 00:00:00 2001 From: Vaxry <43317083+vaxerski@users.noreply.github.com> Date: Tue, 11 Jun 2024 17:17:45 +0200 Subject: core: move to hyprutils for utils (#6385) * core: move to hyprutils for utils Nix: add hyprutils dep * Meson: add hyprutils dep * flake.lock: update --------- Co-authored-by: Mihai Fufezan --- src/debug/HyprCtl.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src/debug/HyprCtl.cpp') diff --git a/src/debug/HyprCtl.cpp b/src/debug/HyprCtl.cpp index bdb12e58..6f4d74b7 100644 --- a/src/debug/HyprCtl.cpp +++ b/src/debug/HyprCtl.cpp @@ -16,6 +16,9 @@ #include #include +#include +using namespace Hyprutils::String; + #include "../config/ConfigDataValues.hpp" #include "../config/ConfigValue.hpp" #include "../managers/CursorManager.hpp" @@ -826,7 +829,7 @@ std::string bindsRequest(eHyprCtlOutputFormat format, std::string request) { std::string versionRequest(eHyprCtlOutputFormat format, std::string request) { - auto commitMsg = removeBeginEndSpacesTabs(GIT_COMMIT_MESSAGE); + auto commitMsg = trim(GIT_COMMIT_MESSAGE); std::replace(commitMsg.begin(), commitMsg.end(), '#', ' '); if (format == eHyprCtlOutputFormat::FORMAT_NORMAL) { @@ -1051,7 +1054,7 @@ std::string dispatchBatch(eHyprCtlOutputFormat format, std::string request) { request = ""; } - curitem = removeBeginEndSpacesTabs(curitem); + curitem = trim(curitem); }; nextItem(); @@ -1305,7 +1308,7 @@ std::string dispatchGetOption(eHyprCtlOutputFormat format, std::string request) request = ""; } - curitem = removeBeginEndSpacesTabs(curitem); + curitem = trim(curitem); }; nextItem(); -- cgit v1.2.3