| 100 | } |
| 101 | |
| 102 | std::string make_timestamp() { |
| 103 | const auto now = std::chrono::system_clock::now(); |
| 104 | const auto time = std::chrono::system_clock::to_time_t(now); |
| 105 | std::tm tm = {}; |
| 106 | #if defined(_WIN32) |
| 107 | localtime_s(&tm, &time); |
| 108 | #else |
| 109 | localtime_r(&time, &tm); |
| 110 | #endif |
| 111 | std::ostringstream out; |
| 112 | out << std::put_time(&tm, "%Y%m%d-%H%M%S"); |
| 113 | return out.str(); |
| 114 | } |
| 115 | |
| 116 | engine::core::BackendType parse_backend(const std::string & value) { |
| 117 | const std::string lowered = lower_ascii(value); |