Skip to content
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

Provide custom success/failure messages #149

Open
1 of 4 tasks
chrissv opened this issue Feb 5, 2020 · 2 comments
Open
1 of 4 tasks

Provide custom success/failure messages #149

chrissv opened this issue Feb 5, 2020 · 2 comments
Assignees
Milestone

Comments

@chrissv
Copy link

chrissv commented Feb 5, 2020

What is the purpose of your issue?

  • Bug report (encountered problems with amazon-dash)
  • Feature request (request for a new functionality)
  • Question
  • Other

Description

Currently the text for the confirmation is either the output of the command, or a generic The {} device has been executed successfully.
This enhancement is to provide custom success and failure text in the yml file for the confirmations, for example:

devices:
  78:e1:03:b5:44:aa:
    name: test_button
    cmd: some_command
    ssh: localhost
    confirmation: send-tg
    msg_success: {name} light is turned on
    msg_failure: Something bad happened with {name} - check log

(msg_success and msg_failure are the new parameters, as a suggestion)

In addition to the new messages, it would be nice to have some kind of primitive substitutions within the messages for things like the name, and maybe others that would make sense (such as date and time, and output from the cmd).

@Nekmo Nekmo self-assigned this Feb 25, 2020
@Nekmo Nekmo added this to the v1.5.0 milestone Mar 1, 2020
@Nekmo
Copy link
Owner

Nekmo commented Mar 1, 2020

Added to milestone v1.5.0!

@chrissv
Copy link
Author

chrissv commented Mar 1, 2020

Do you plan on adding any variable substitutions, like {name} and/or {date}? If so, which ones make sense?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants