DomT4 / homebrew-autoupdate

:tropical_drink: An easy, convenient way to automatically update Homebrew.
BSD 2-Clause "Simplified" License
995 stars 55 forks source link

Add terminal-notifier as a recommended/optional depency #25

Closed TheHarcker closed 3 years ago

TheHarcker commented 4 years ago

It would be nice if terminal-notifier would be listed as a (required/optional/recommended) dependency for brew to install along with autoupdate.

Will the above be impossible due to this only being a tap and not a full fledged formula?

If it is impossible, it would be nice to have a simple brew install terminal-notifier in the README.md

DomT4 commented 4 years ago

It would be nice if terminal-notifier would be listed as a (required/optional/recommended) dependency for brew to install along with autoupdate.

I've put a fair bit of thought into this over time. My thoughts have generally pooled into:

RogierdeRuijter commented 4 years ago

Would it be possible to rewrite the notification output to use system notifications without needing an external dependency to achieve this, without increasing the maintenance this project requires significantly?

@DomT4 Hi, the part you wrote above sparked my interest.

It seems to be possible to create a system notification from an AppleScript script. If we are able to run an AppleScript and get the clients system to trust this script, this might be doable.

Let me know what you think!

Source

DomT4 commented 3 years ago

https://github.com/DomT4/homebrew-autoupdate/commit/6365cc020c6bca3c9096daf5e687617578d9350f, https://github.com/DomT4/homebrew-autoupdate/commit/f31a1618c5efb7bc8dffc857a6dbbd28474308a9, https://github.com/DomT4/homebrew-autoupdate/commit/8b12c227ad03f11215c671c8a05e21edb28feaaa, https://github.com/DomT4/homebrew-autoupdate/commit/e2b76a08fbe709ca7b4b453abdd43a8137c1ae34, https://github.com/DomT4/homebrew-autoupdate/commit/6a084e3280c302feb1ac1650d00ea53cf4571f80, https://github.com/DomT4/homebrew-autoupdate/commit/6bc10b3475dd72545a0f686be3e82cbe53a33335, https://github.com/DomT4/homebrew-autoupdate/commit/322bb03f235004a8e49157db072e1037807e5768 together implements a new, experimental notification system that uses Applescript to execute and doesn't rely on or need any external dependencies. At the moment it only runs on macOS Big Sur, which is largely my way of testing it in a limited roll-out before turning it on for everyone. The applet is also codesigned, so should run on other macOS machines.

As with most brew-autoupdate changes to cause minimal disruption I haven't automatically pushed the change through to users locally; if you wanted to change to the new notification system on Big Sur you'd need to manually brew autoupdate --delete and then brew autoupdate --start again.

DomT4 commented 3 years ago

Folded into https://github.com/Homebrew/homebrew-autoupdate/issues/43.