prefer std::format over fmt
Now that std::format is implemented we aren't using complex enough fmt
to warrant using it over the std version. Switch to std and remove the
dependency.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Ib03cdb6a9db4d25de345bdb49b28157880c19bc1
diff --git a/chassis_state_manager_main.cpp b/chassis_state_manager_main.cpp
index af572f1..aecf9a9 100644
--- a/chassis_state_manager_main.cpp
+++ b/chassis_state_manager_main.cpp
@@ -2,7 +2,6 @@
#include "chassis_state_manager.hpp"
-#include <fmt/format.h>
#include <getopt.h>
#include <sdbusplus/bus.hpp>
@@ -10,6 +9,7 @@
#include <cstdlib>
#include <exception>
#include <filesystem>
+#include <format>
#include <iostream>
constexpr auto LEGACY_POH_COUNTER_PERSIST_PATH =
@@ -55,9 +55,9 @@
fs::path legacyPohPath{LEGACY_POH_COUNTER_PERSIST_PATH};
fs::path legacyStateChangePath{LEGACY_STATE_CHANGE_PERSIST_PATH};
- fs::path newPohPath{fmt::format(POH_COUNTER_PERSIST_PATH, chassisId)};
+ fs::path newPohPath{std::format(POH_COUNTER_PERSIST_PATH, chassisId)};
fs::path newStateChangePath{
- fmt::format(CHASSIS_STATE_CHANGE_PERSIST_PATH, chassisId)};
+ std::format(CHASSIS_STATE_CHANGE_PERSIST_PATH, chassisId)};
if (fs::exists(legacyPohPath))
{
fs::rename(legacyPohPath, newPohPath);