Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Epixu committed Jul 10, 2024
1 parent d38345c commit d932772
Showing 1 changed file with 10 additions and 11 deletions.
21 changes: 10 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -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
Expand All @@ -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)
Expand All @@ -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 <Logger/Logger.hpp>
using namespace Langulus;
Expand All @@ -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).
Expand Down

0 comments on commit d932772

Please sign in to comment.