-
Notifications
You must be signed in to change notification settings - Fork 5
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
Add restart feature #37
Conversation
No test were added, USAGE.md wasn't updated. If needed I can update PR with those or anything else needed. |
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.
Looks fine, please add tests (at least for cli invocation with a new command) and you can update readme as well.
@@ -340,3 +357,17 @@ def signal(self, hap: Hap, sig: signal.Signals): | |||
f"{config.ICON_INFO} Cannot send signal to the inactive hap", | |||
style=f"{config.COLOR_ERROR} bold", | |||
) | |||
|
|||
def restart(self, hap: Hap): | |||
hid, name, cmd = hap.hid, hap.name, hap.cmd |
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.
maybe name should contain -restarted
suffix or something to have some hint for the user? wdyt
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.
Hmm, I would maybe personally prefer it without a suffix. If needed, some flag like --suffix
or --no-suffix
can be added.
@fpankretic thanks for your contribution! |
#35