Skip to content

Very efficient, convenient, thread-safe, flexible and simple logger

License

Notifications You must be signed in to change notification settings

igorkorsukov/kors_logger

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

logger

Very efficient, convenient, thread-safe, flexible and simple logger with Qt support (if enabled)
Requires C++17 and higher.

Features:

  • Stream and formatted input
  • Many destinations
  • Coloured console output
  • Log levels, types, tags
  • Extremely small overhead for disabled debug
  • Catch Qt messages (if enabled)
  • Custom output format
  • Custom messages types
  • Filter by type

Example

example_log

Used in at least two private commercial projects and one open source.

Integration

Add source

To use Logger within your software project include the Logger source into your project

Source:

  • logger.h/cpp - logger and base stuff
  • logdefdest.h/cpp - default destinations for console and file
  • log_base.h - macro for simple use logger
  • logstream.h - log stream, it can be used to add output operator for your types
  • funcinfo.h - macros for parsing signatures

or include logger.cmake in the cmake project (see example/CMakeLists.txt)

Add aliases

Recommended add own aliases to use logger stuff (type, level, color and etc) See example:

ChangeLog

v1.3

  • Added useful macros
  • Improved parsing of function signatures
  • Removed rotate from FileLogDest (now files management should be outside)

v1.2

v1.1

v1.0

About

Very efficient, convenient, thread-safe, flexible and simple logger

Resources

License

Stars

Watchers

Forks