Files
dm-cli/dm-cli/common.hpp
2025-11-27 13:31:48 +03:00

27 lines
779 B
C++
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#ifndef _COMMON_
#define _COMMON_
#include <string>
#define PROGRAM_VERSION "1.0.1"
// LANG=ru_RU.UTF-8
#define LANG_RU "ru_RU.UTF-8"
#define DEFAULTADDRESS "127.0.0.1:4999"
/*
Show help screen.
*/
void show_help(bool isRulang);
/// @brief Отображает отладочную информацию
void ShowDebug(std::string url, std::string result, bool success, std::string decoded);
/// @breef Replace in string
std::string Replace(std::string source, std::string from, std::string out);
/// @breef Replace all entryes in string
std::string ReplaceAll(std::string str, const std::string &from, const std::string &to);
/// @breef Вывод сообщения о таймауте или пустой строке ответа
int NoResponse(std::string mgs);
#endif