daboross / fern

Simple, efficient logging for Rust
MIT License
848 stars 51 forks source link

Possible to chain more files after already intializing a logger? #94

Closed smahm006 closed 6 months ago

smahm006 commented 2 years ago

Hello, I am building a test script in rust to test the hardware on some devices i own. The script starts off with creating a root logger in a logs/root folder and then scans the local network to find any of the devices to test. What I would like to do is after the devices are found, to create a new directory in the root folder for each device found and then create a device logger for each device found.

If you ask why I cannot create the logger after scanning for my devices, well I would like to log the devices found in the root logger.

It seems you cannot modify a logger once it has been initialized, but I'll ask anyways, is it possible to add extra chains to the initial Dispatch created?