Skip to content

Commit

Permalink
Add filewatcher/v2
Browse files Browse the repository at this point in the history
Being the first lib implemented in baseplate.go and long predates
generics, the API of filewatcher lacks type safety and can cause other
annoyances.

Add filewatcher/v2 that provides:

* Generics/type safety
* Use io.Closer over Stop()
* Use With- options over a Config struct
* Use slog at error level over log wrapper

And change original filewatcher lib to a thin wrapper of v2.

This change intentionally does not change any of its users (experiments,
secrets, etc.), as a proof that we did not break v0 API. The next change
will switch them to use v2.
  • Loading branch information
fishy committed May 22, 2024
1 parent f1ad2b4 commit 126d45b
Show file tree
Hide file tree
Showing 7 changed files with 1,270 additions and 342 deletions.
Loading

0 comments on commit 126d45b

Please sign in to comment.