2010-07-21 04:43:41 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class Ringojs < Formula
|
2011-08-09 05:47:54 +00:00
|
|
|
url 'https://github.com/downloads/ringo/ringojs/ringojs-0.8.tar.gz'
|
2010-07-21 04:43:41 +00:00
|
|
|
homepage 'http://ringojs.org'
|
2011-08-09 05:47:54 +00:00
|
|
|
md5 '405455f7ab1bc7e230ff2ef50ced01c4'
|
2010-07-21 04:43:41 +00:00
|
|
|
|
|
|
|
def shim_script target
|
|
|
|
<<-EOS.undent
|
|
|
|
#!/bin/bash
|
2012-02-11 23:45:42 +00:00
|
|
|
"#{libexec}/bin/#{target}" "$@"
|
2010-07-21 04:43:41 +00:00
|
|
|
EOS
|
|
|
|
end
|
|
|
|
|
|
|
|
def install
|
|
|
|
rm Dir['bin/*.cmd']
|
|
|
|
libexec.install Dir['*']
|
|
|
|
|
|
|
|
Dir["#{libexec}/bin/*"].each do |b|
|
|
|
|
n = Pathname.new(b).basename
|
|
|
|
(bin+n).write shim_script(n)
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|