homebrew-core/Formula/yafc.rb
2019-11-04 13:53:58 +09:00

36 lines
1.2 KiB
Ruby

class Yafc < Formula
desc "Command-line FTP client"
homepage "https://github.com/sebastinas/yafc"
url "https://deb.debian.org/debian/pool/main/y/yafc/yafc_1.3.7.orig.tar.xz"
sha256 "4b3ebf62423f21bdaa2449b66d15e8d0bb04215472cb63a31d473c3c3912c1e0"
revision 4
bottle do
cellar :any
sha256 "07a19edcc11987e0de79538413a41b683c86de41d216eb2c120f747a3564bfd4" => :catalina
sha256 "f01687e9e00211d729d0d6bb191d6286b41693c52ecf2e6c5a26874c27589daa" => :mojave
sha256 "d2344380f7cee870732888ac9675303edd374400d5c1bbde02f822d09e93d186" => :high_sierra
end
depends_on "pkg-config" => :build
depends_on "libssh"
depends_on "readline"
def install
args = %W[
--prefix=#{prefix}
--with-readline=#{Formula["readline"].opt_prefix}
]
system "./configure", *args
system "make", "install"
end
test do
download_file = testpath/"512KB.zip"
expected_checksum = Checksum.new("sha256", "07854d2fef297a06ba81685e660c332de36d5d18d546927d30daad6d7fda1541")
output = pipe_output("#{bin}/yafc -W #{testpath} -a ftp://speedtest.tele2.net/", "get #{download_file.basename}", 0)
assert_match version.to_s, output
download_file.verify_checksum expected_checksum
end
end