2014-03-30 19:40:35 +00:00
|
|
|
require "language/haskell"
|
|
|
|
|
|
|
|
class Darcs < Formula
|
|
|
|
include Language::Haskell::Cabal
|
|
|
|
|
2015-05-19 00:00:59 +00:00
|
|
|
desc "Distributed version control system that tracks changes, via Haskell"
|
2014-03-30 19:40:35 +00:00
|
|
|
homepage "http://darcs.net/"
|
2015-11-20 02:38:41 +00:00
|
|
|
url "http://darcs.net/releases/darcs-2.10.2.tar.gz"
|
|
|
|
sha256 "6337d3fac04711fa2ef5813558b409c59166c5599b0c9d68c418d21cdccfb327"
|
2014-03-30 19:40:35 +00:00
|
|
|
|
2014-05-06 22:52:15 +00:00
|
|
|
bottle do
|
2015-11-20 03:24:09 +00:00
|
|
|
sha256 "7233b3d0fd8fbae5c3dd6f8229fd2755ce047961c6692eaeeb63064f7184fd29" => :el_capitan
|
|
|
|
sha256 "62a0c990b8585130d6c8955d2884ec07030dd1b3c5b0f711126a9dd9b5762d02" => :yosemite
|
|
|
|
sha256 "edd6a36b7146e20cf5a6a3bbe70737f6013f855bbb881523bdf460e416d9626a" => :mavericks
|
2014-05-06 22:52:15 +00:00
|
|
|
end
|
|
|
|
|
2014-03-30 19:40:35 +00:00
|
|
|
depends_on "ghc" => :build
|
|
|
|
depends_on "cabal-install" => :build
|
|
|
|
depends_on "gmp"
|
|
|
|
|
2015-05-29 02:30:10 +00:00
|
|
|
setup_ghc_compilers
|
|
|
|
|
2014-03-30 19:40:35 +00:00
|
|
|
def install
|
|
|
|
install_cabal_package
|
|
|
|
end
|
|
|
|
|
|
|
|
test do
|
|
|
|
mkdir "my_repo" do
|
|
|
|
system "darcs", "init"
|
|
|
|
(Pathname.pwd/"foo").write "hello homebrew!"
|
|
|
|
system "darcs", "add", "foo"
|
|
|
|
system "darcs", "record", "-am", "add foo", "--author=homebrew"
|
|
|
|
end
|
|
|
|
system "darcs", "get", "my_repo", "my_repo_clone"
|
|
|
|
Dir.chdir "my_repo_clone" do
|
2015-10-05 13:15:35 +00:00
|
|
|
assert_match "hello homebrew!", (Pathname.pwd/"foo").read
|
2014-03-30 19:40:35 +00:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|