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

ntfy CLI #46

Closed
binwiederhier opened this issue Dec 9, 2021 · 2 comments
Closed

ntfy CLI #46

binwiederhier opened this issue Dec 9, 2021 · 2 comments
Labels
enhancement New feature or request in-progress 🏃 I'm working on this right now

Comments

@binwiederhier
Copy link
Owner

The CLI could consist of 3 features:

Server

Just like today, possibly rename command to ntfy serve

Subscribe to topics

Just like curl:

$ ntfy subscribe mytopic1,mytopic2 
{"id":"UiLWPRJAi1","time":1639044609,"event":"message","topic":"mytopic1","message":"It is Thu Dec 09 2021 17:10:09 GMT+0700 (Western Indonesia Time). This is a test."}
{"id":"idFle3ak4S","time":1639074191,"event":"message","topic":"mytopic2","message":"Test"}
...

With a hook:

$ ntfy subscribe mytopic1,mytopic2 --hook 'notify-send "{{.Message}}'

As part of the daemon

$ cat config.yml
subscribe:
   - 
     - topic: ntfy.sh/mytopic
     - hook: 'notify-send "{{.Message}}'

$ ntfy serve # runs daemon

Send messages

ntfy send mytopic "This is a message"
...
@binwiederhier binwiederhier added the enhancement New feature or request label Dec 9, 2021
binwiederhier pushed a commit that referenced this issue Dec 17, 2021
@binwiederhier binwiederhier added the in-progress 🏃 I'm working on this right now label Dec 17, 2021
@binwiederhier
Copy link
Owner Author

I am still working on this with great progress. It's just taking longer than expected.

@binwiederhier
Copy link
Owner Author

Done in 1.8.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request in-progress 🏃 I'm working on this right now
Projects
None yet
Development

No branches or pull requests

1 participant