From: Vincent Bernat Date: Fri, 10 Sep 2021 06:35:40 +0000 (+0200) Subject: osx: replace plist by service in brew recipe X-Git-Tag: 1.0.13~18 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f28fc79d7816a33af669d141e4234f592023c140;p=thirdparty%2Flldpd.git osx: replace plist by service in brew recipe --- diff --git a/osx/lldpd.rb b/osx/lldpd.rb index c73157d7..e8f0d563 100644 --- a/osx/lldpd.rb +++ b/osx/lldpd.rb @@ -81,26 +81,8 @@ class Lldpd < Formula end plist_options startup: true - - def plist - additional_args = "" - additional_args += "-x" if build.with? "snmp" - <<~EOS - - - - - Label - #{plist_name} - ProgramArguments - - #{opt_sbin}/lldpd - #{additional_args} - - RunAtLoad - KeepAlive - - - EOS + service do + run build.with?("snmp") ? [opt_sbin/"lldpd", "-x"] : opt_sbin/"lldpd" + keep_alive true end end