From a1f24748e695aa50a8142a5c510261d1e6e1fe4e Mon Sep 17 00:00:00 2001 From: Morgan Tocker Date: Mon, 11 Mar 2019 13:59:34 -0600 Subject: [PATCH] caveats: non-macOS platforms warn on services Only currently supported by macOS. Attempting to use services should produce a warning for now. It is possible it might be supported in the future. --- Library/Homebrew/caveats.rb | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/Library/Homebrew/caveats.rb b/Library/Homebrew/caveats.rb index 7a85c71897..cbeb8a2335 100644 --- a/Library/Homebrew/caveats.rb +++ b/Library/Homebrew/caveats.rb @@ -136,7 +136,18 @@ class Caveats EOS end - def plist_caveats; end + def plist_caveats + return unless f.plist_manual + + # default to brew services not being supported. + # macOS will overwrite this behavior. + + <<~EOS + #{Formatter.warning("Warning:")} #{f.name} wants to install a service, which is currently only supported on macOS! + You can manually execute the service with: + #{f.plist_manual} + EOS + end def plist_path destination = if f.plist_startup