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.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(cli): add support for poll watcher #21290
feat(cli): add support for poll watcher #21290
Changes from 5 commits
ae66312
1802ece
ed86d4a
4bee121
da73600
e31bec0
d07c4b3
0805634
524fb0a
ad936cc
3f1310b
46c5763
56fdf20
94420b8
8a38f2f
2822555
3f3000c
72a68ea
b7accf4
602ff3f
6a914ca
f38ad11
14c0e72
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if we can refactor
create_watcher
to use theWatchConfigMethod
enum directly. AFAIK, due to clap parsing, theWatchConfigMethod
needs to have plain enum variants.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since i want that enum to have values about the interval and i don't want to pass the interval in the function parameters.
One thing we can do is we can eliminate is watch config method enum. we can make it as string and add the possible values for
clap
arguments. using that we can create theWatcherConfig
enumThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: any reason to use this here vs at the top like the other imports?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually we already have name watcher as enum. it was colliding with watcher from
notify
.Renaming the import at the top level user might not able to understand what is
NotifyWathcher
and we need the methods fornotify::Watcher
on that specific scope. that's why i used Watcher on the specific scope