2011-03-10 05:11:03 +00:00
|
|
|
class Jsawk < Formula
|
2015-05-19 00:00:59 +00:00
|
|
|
desc "Like awk, but for JSON, using JavaScript objects and arrays"
|
2015-01-13 09:51:42 +00:00
|
|
|
homepage "https://github.com/micha/jsawk"
|
|
|
|
url "https://github.com/micha/jsawk/archive/1.4.tar.gz"
|
2015-08-03 12:55:31 +00:00
|
|
|
sha256 "3d38ffb4b9c6ff7f17072a12c5817ffe68bd0ab58d6182de300fc1e587d34530"
|
2013-03-28 19:06:45 +00:00
|
|
|
|
2015-01-13 09:51:42 +00:00
|
|
|
head "https://github.com/micha/jsawk.git"
|
2010-04-07 05:58:35 +00:00
|
|
|
|
2015-01-13 09:51:42 +00:00
|
|
|
depends_on "spidermonkey"
|
2009-11-24 17:10:35 +00:00
|
|
|
|
|
|
|
def install
|
|
|
|
bin.install "jsawk"
|
|
|
|
end
|
2015-01-13 09:51:42 +00:00
|
|
|
|
|
|
|
test do
|
|
|
|
cmd = %(#{bin}/jsawk 'this.a = "foo"')
|
|
|
|
assert_equal %({"a":"foo"}\n), pipe_output(cmd, "{}")
|
|
|
|
end
|
2009-11-24 17:10:35 +00:00
|
|
|
end
|