From 95ced67e0406b4eceb7e744f929b5ff57b6cacf8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lia=20Br=C3=BCggemann?= <118379719+BlyDoesCoding@users.noreply.github.com> Date: Wed, 28 May 2025 21:10:52 +0200 Subject: [PATCH] Create loger.c --- c/loger.c | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 c/loger.c diff --git a/c/loger.c b/c/loger.c new file mode 100644 index 0000000..b1d9208 --- /dev/null +++ b/c/loger.c @@ -0,0 +1,29 @@ +#include + + +/*prints the given string in cyan + +*/ +void info(char message[]) { + + printf(" \e[0;36m%s\e[0m\n", message); + return; +} + +/*prints the given string in RED with a ERROR before + +*/ +void error(char message[]) { + + printf("[\e[1;91mERROR\e[0m] \e[0;91m%s\e[0m\n", message); + return; +} + +/*prints the given string in yellow with a INFO before + +*/ +void warning(char message[]) { + + printf("[\e[1;93mINFO\e[0m] \e[0;93m%s\e[0m\n", message); + return; +}