folkertvanheusden / multitail

Tail on steroids
https://vanheusden.com/multitail/
MIT License
129 stars 13 forks source link

Feature request: dynamically add windows as watched files appear #37

Open cbeams opened 5 months ago

cbeams commented 5 months ago

multitail can watch a glob of files, e.g. *.log with its -iw option, such that the most recently updated file matching that glob is dynamically "swapped in" to the multitail window over the course of the session.

multitail can also watch one or more not-yet existent files with its --retry and --retry-all options.

and multitail can add windows to an already running session using its interactive menus.

I'm interested in a new feature that would combine aspects of all of these existing capabilities. With it, I would be able to:

  1. run multitail with a certain layout;
  2. against a glob of files that do not yet exist;
  3. and then observe the running multitail session dynamically add windows to accommodate new files as they are created

My use case is a live demo in which I want to start multitail with a single empty window and then have new windows appear in a 3x3 grid (-s 3 -sn 3,3,3) as watched files matching a certain glob appear. The files in question are log files for processes I am creating during the course of the demo. This is simply a cool visual / aesthetic effect I'm trying to achieve. It seems that multitail already has all the underlying functionality to make it possible, but that these pieces just haven't yet been "put together" such that I can make the described behavior happen. Thanks for considering.