Skip to content

builtin/cli_defines.h

Functions

Name
std::string repStr(std::string const & s, size_t n)
std::string colorizeJson(nlohmann::json const & j, int indent =0, bool lastElement =false)

Defines

Name
ANSI_COLOR_RED
ANSI_COLOR_GREEN
ANSI_COLOR_BLUE
ANSI_COLOR_GREEN_BOLD
ANSI_COLOR_WHITE
ANSI_COLOR_DIM_WHITE
ANSI_COLOR_CYAN
ANSI_COLOR_YELLOW
ANSI_COLOR_RESET
HEADER_SEPERATOR
HEADER_COLOR
HIGHLIGHT_COLOR
ERROR_COLOR
INFO_COLOR
RESET
KEY_COLOR
STRING_COLOR
BRACE_COLOR

Functions Documentation

function repStr

inline std::string repStr(
    std::string const & s,
    size_t n
)

function colorizeJson

inline std::string colorizeJson(
    nlohmann::json const & j,
    int indent =0,
    bool lastElement =false
)

Macros Documentation

define ANSI_COLOR_RED

#define ANSI_COLOR_RED "\x1b[31m"

define ANSI_COLOR_GREEN

#define ANSI_COLOR_GREEN "\x1b[32m"

define ANSI_COLOR_BLUE

#define ANSI_COLOR_BLUE "\x1b[34m"

define ANSI_COLOR_GREEN_BOLD

#define ANSI_COLOR_GREEN_BOLD "\x1b[1;32m"

define ANSI_COLOR_WHITE

#define ANSI_COLOR_WHITE "\x1b[1;37m"

define ANSI_COLOR_DIM_WHITE

#define ANSI_COLOR_DIM_WHITE "\x1b[37m"

define ANSI_COLOR_CYAN

#define ANSI_COLOR_CYAN "\x1b[36m"

define ANSI_COLOR_YELLOW

#define ANSI_COLOR_YELLOW "\x1b[33m"

define ANSI_COLOR_RESET

#define ANSI_COLOR_RESET "\x1b[0m"

define HEADER_SEPERATOR

#define HEADER_SEPERATOR "-"

define HEADER_COLOR

#define HEADER_COLOR ANSI_COLOR_GREEN

define HIGHLIGHT_COLOR

#define HIGHLIGHT_COLOR ANSI_COLOR_YELLOW

define ERROR_COLOR

#define ERROR_COLOR ANSI_COLOR_RED

define INFO_COLOR

#define INFO_COLOR ANSI_COLOR_CYAN

define RESET

#define RESET "\033[0m"

define KEY_COLOR

#define KEY_COLOR "\033[1;34m"

define STRING_COLOR

#define STRING_COLOR "\033[0;32m"

define BRACE_COLOR

#define BRACE_COLOR "\033[1;33m"

Updated on 2025-08-24 at 15:42:37 +0000