bitcoin: add plist (#18704)

This commit is contained in:
Alejandro Avilés 2017-09-29 16:58:56 +02:00 committed by ilovezfs
parent ab315476a0
commit 01808f41c8

View file

@ -35,6 +35,26 @@ class Bitcoin < Formula
system "make", "install"
end
plist_options :manual => "bitcoind"
def plist; <<-EOS.undent
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>#{plist_name}</string>
<key>ProgramArguments</key>
<array>
<string>#{opt_bin}/bitcoind</string>
</array>
<key>RunAtLoad</key>
<true/>
</dict>
</plist>
EOS
end
test do
system "#{bin}/test_bitcoin"
end