require 'formula' class OfflineImap < Formula homepage 'http://offlineimap.org/' url 'https://github.com/OfflineIMAP/offlineimap/archive/v6.5.5.zip' sha1 '90541e4f6d439edf0aa0afbff2b4bfc1c1f10d10' head 'https://github.com/OfflineIMAP/offlineimap.git' def install prefix.install 'offlineimap.conf', 'offlineimap.conf.minimal' libexec.install 'bin/offlineimap' => 'offlineimap.py' libexec.install 'offlineimap' bin.install_symlink libexec+'offlineimap.py' => 'offlineimap' end def caveats; <<-EOS.undent To get started, copy one of these configurations to ~/.offlineimaprc: * minimal configuration: cp -n #{prefix}/offlineimap.conf.minimal ~/.offlineimaprc * advanced configuration: cp -n #{prefix}/offlineimap.conf ~/.offlineimaprc EOS end def plist; <<-EOS.undent KeepAlive Label #{plist_name} ProgramArguments #{opt_prefix}/bin/offlineimap StartInterval 300 RunAtLoad StandardErrorPath /dev/null StandardOutPath /dev/null EOS end end