Skip to content

Commit

Permalink
saldl 31 (new formula)
Browse files Browse the repository at this point in the history
Closes Homebrew/legacy-homebrew#45850.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
  • Loading branch information
robertgzr authored and MikeMcQuaid committed Nov 24, 2015
1 parent 33dc977 commit c53c8bf
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions Formula/saldl.rb
@@ -0,0 +1,38 @@
class Saldl < Formula
desc "CLI downloader optimized for speed and early preview."
homepage "https://saldl.github.io"
url "https://github.com/saldl/saldl/archive/v31.tar.gz"
sha256 "146a980ae2109a391c7a8ab6a1c525458db9bf18f3f0477731c9b876630078b4"
head "https://github.com/saldl/saldl.git", :shallow => false

depends_on "pkg-config" => :build
depends_on "asciidoc" => :build
depends_on "docbook-xsl" => :build
depends_on "libevent"

if MacOS.version <= :mavericks
# curl >= 7.42 is required
depends_on "curl"
else
depends_on "curl" => :optional
end

def install
# a2x/asciidoc needs this to build the man page successfully
ENV["XML_CATALOG_FILES"] = "#{etc}/xml/catalog"

args = ["--prefix=#{prefix}"]

# head uses git describe to acquire a version
args << "--saldl-version=v#{version}" unless build.head?

system "./waf", "configure", *args
system "./waf", "build"
system "./waf", "install"
end

test do
system "#{bin}/saldl", "http://brew.sh/index.html"
assert File.exist? "index.html"
end
end

0 comments on commit c53c8bf

Please sign in to comment.