blob: 5687bff9eaa5d1389b1b9b84450f3a90bd23b338 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
require 'formula'
class Calabash < Formula
homepage 'http://xmlcalabash.com'
url 'http://xmlcalabash.com/download/calabash-1.0.2-94.zip'
md5 '76e3c709ce013ab77f5e09bb8a41bd5b'
head 'https://github.com/ndw/xmlcalabash1.git'
depends_on 'saxon'
def install
libexec.install Dir["*"]
(bin+'calabash').write shim_script('calabash')
end
def shim_script target
<<-EOS.undent
#!/usr/bin/env bash
java -Xmx1024m -jar #{libexec}/calabash.jar "$@"
EOS
end
def test
# This small XML pipeline (*.xpl) that comes with Calabash
# is basically its equivalent "Hello World" program.
system "#{bin}/calabash", "#{libexec}/xpl/pipe.xpl"
end
end
|