Skip to content

Add srt-logger tool

Simon McVittie requested to merge wip/smcv/logger into main


  • !677 (merged)

  • tests: Add adverb --exclusive-lock

    This takes a lock, but only briefly. It will be used in a subsequent commit, as a way for tests to wait for all processes holding locks on a log file to exit.

  • srt-logger: New tool to divert command output to a log

    By default, this tees output to a log file and its own standard error stream. It also optionally writes to the systemd Journal.

    The log file is written with a size limit: if it would become larger than its size limit, it's moved out of the way and logging resumes in a newly created file. This is similar to how the Steam client's internal logging in C++ code works. Log rotation is automatically disabled if more than one srt-logger process is trying to write to the same log, to avoid data loss.

  • tests: Test the logger

Edited by Simon McVittie

Merge request reports