A header only library for capturing and tee-ing std::cout to a file.
- C++ 98.1%
- CMake 1.9%
|
|
||
|---|---|---|
| .clang-format | ||
| .gitignore | ||
| CMakeLists.txt | ||
| example.cpp | ||
| LICENSE.md | ||
| README.md | ||
| tattl.hpp | ||
tattl
tattl is a header only library that hijacks cout to attach it to a log file.
Usage
Anywhere in the application, include tattl.hpp and create a static instance of the tail_t object. Afterwards, anywhere std::cout is used it will be printed to the log file specified.
# include <tattl.hpp>
static tattl::tail_t tail("app.log");
Example
An example of usage is provided in example.cpp. To build and run the example, run the command cmake -B build -G Ninja; cmake --build build; ./build/example in the top level directory.
Legal
Copyright© 2026 Billy Ray Fortenbury (br410bury). See LICENSE.md for license details.