From d932772e25000b844515b37fa52a33470fd146af Mon Sep 17 00:00:00 2001 From: Dimo Markov Date: Wed, 10 Jul 2024 20:31:48 +0300 Subject: [PATCH] Update README.md --- README.md | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index 248abf5..bdfa7ae 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,13 @@ [![Langulus::Logger CI](https://github.com/Langulus/Logger/actions/workflows/ci.yml/badge.svg)](https://github.com/Langulus/Logger/actions/workflows/ci.yml) # Langulus::Logger -`Langulus::Logger` is a stateful C++23 logger library based on [{fmt} library](https://github.com/fmtlib/fmt), capable of logging to a console and/or and HTML file. It is used in [all other Langulus](https://github.com/Langulus) libraries and plug-ins. -It contains about a dozen highly-inlined variadic functions with different styles for a consistently pretty and easy logging experience. +`Langulus::Logger` is a cross-platform, stateful C++23 logger library based on [{fmt} library](https://github.com/fmtlib/fmt), capable of logging to console and/or HTML files. +It is used in [all other Langulus](https://github.com/Langulus) libraries and plug-ins. +It contains about a dozen inlined variadic functions with different styles for a consistently pretty and easy logging experience. -This is how it looks in Windows 10 Terminal: +### This is how it looks in Windows 10 Terminal: ![Windows Terminal](test/expected_win_console.png) -This is how it looks when logging to a HTML file (Chrome web browser): +### This is how it looks when logging to an HTML file (as seen via Chrome web browser): ![Chrome Browser](test/expected_chrome.png) # Getting the library @@ -15,7 +16,8 @@ If you have CMake 3.28+, the easiest way to get this library is to use `FetchCon include(FetchContent) FetchContent_Declare(LangulusLogger GIT_REPOSITORY https://github.com/Langulus/Logger.git - GIT_TAG main # you should use a specific commit/release, so that you can control when to bump your dependencies + GIT_TAG main # you should use a specific commit/release, + # so that you can control when to bump your dependencies EXCLUDE_FROM_ALL ) FetchContent_MakeAvailable(LangulusLogger) @@ -24,13 +26,10 @@ Then just link to your target to get all the include directories: ```cmake target_link_libraries(YourLibrary PUBLIC LangulusLogger) ``` -This will also automatically fetch all dependencies - [{fmt}](https://github.com/fmtlib/fmt) and [Langulus::Core](https://github.com/Langulus/Core). - ---------------- -Alternatively, you can just download and copy the files from `source/` to your build tree, but you will also have to download and copy the dependencies, too. Don't forget to add `Logger.cpp` to your target. +This will also automagically fetch all dependencies: [{fmt}](https://github.com/fmtlib/fmt) and [Langulus::Core](https://github.com/Langulus/Core). # Using the library -After linking with LangulusLogger, you can include it in your files, and call the required functions, which are located in the `Langulus::Logger` namespace: +After linking with LangulusLogger, you can include it in your files and call the required functions, which are located in the `Langulus::Logger` namespace: ```c++ #include using namespace Langulus; @@ -43,7 +42,7 @@ int main(int argc, char* argv[]) { Visit the Wiki for a full list of the [available functions](https://github.com/Langulus/Logger/wiki/API) and [customization points](https://github.com/Langulus/Logger/wiki/Customization-points). # Considerations -Langulus::Logger's API is unlikely to change drastically - only a couple of additonal features remain to be added. +Langulus::Logger's API is unlikely to change drastically - only a couple of additional features remain to be added. # Community feedback I would love feedback and suggestions, please feel free to join the [forum](https://github.com/Langulus/Logger/discussions).