docs: add FileOutput date-based example #56 - #118
Open
AzazelSensei wants to merge 2 commits into
Open
Conversation
Show writing logs to log-YYYY-M-D.txt in the README.
Bungeefan
reviewed
Sep 5, 2026
Bungeefan
reviewed
Sep 5, 2026
Comment on lines
+185
to
+186
| `FileOutput` writes logs to a file. Use the current date in the file name to get one | ||
| file per day (`log-2024-2-1.txt`, `log-2024-2-2.txt`, ...): |
Member
There was a problem hiding this comment.
I am wondering if we should clarify that this is not necessarily true if the program keeps running for longer than a day?
(Probably not really applicable in the case of Flutter, but we are focused on Dart)
That said, perhaps the code example already makes this clear enough?
What do you think?
Author
There was a problem hiding this comment.
Yeah, FileOutput will not roll at midnight. The path is fixed when the Logger is created. I made that explicit after the example.
ISO 8601 date in the file name. Note that the path is fixed at Logger creation.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a README example for FileOutput with a date in the file name (log-2024-2-1.txt / log-2024-2-2.txt).
Closes #56