Pages
API Documentation
On this page

Sonic::Logging::Options Struct

What install() sets up. More...

  • Header: #include <Sonic/Logging/Logging>
  • CMake: find_package(SonicLogging REQUIRED)
    target_link_libraries(mytarget PRIVATE Sonic::Logging)

List of all members, including inherited members

Detailed Description

Callers set only the members they change, for example Sonic::Logging::install({.rotateOnStartup = true}).

Member Variable Documentation

QString Options::binaryName

Empty: the name the program was started as, without directories, e.g. "soniclogin-helper".

QStringList Options::dropDebugCategoryExact

Debug messages from exactly these categories are dropped; the empty string is the default category.

QStringList Options::dropDebugCategoryPrefixes

Debug messages from categories starting with any of these are dropped. SonicDE's own (org.sonicde.*) debug messages are never dropped.

QStringList Options::dropDebugMessageSubstrings

Debug messages containing any of these (case-insensitive) are dropped.

bool Options::journald

Also send to journald when it's running.

bool Options::mirrorToStderr

Mirror lines to stderr even when it isn't a terminal, for command-line tools whose stderr a build system or script reads. Ignored when a service manager captures the output (lines already go there) and when stderr is the journal.

bool Options::mirrorToStderrWhenTty

Mirror lines to stderr when it is a terminal and not already the journal.

bool Options::rotateOnStartup

Also rotate to <file>.last on every run. A program running as root then rotates only on startup, not by size.

qint64 Options::rotationSizeBytes

Rotate to <file>.last once the file passes this size. Zero or less turns rotation by size off.

bool Options::writeLogFile

Write the program's own log file. Build tools that run inside package builds turn it off, so they never create /var/log/sonic or a file in the build user's home; lines then go to stderr (and journald).

We use cookies to personalize content and to analyze our traffic. Please decide if you are willing to accept cookies from our website.