88779ade49
Closes Homebrew/homebrew#14653.
32 lines
1.1 KiB
Ruby
32 lines
1.1 KiB
Ruby
require 'formula'
|
|
|
|
class ScalaDocs < Formula
|
|
homepage 'http://www.scala-lang.org/'
|
|
url 'http://www.scala-lang.org/downloads/distrib/files/scala-docs-2.9.2.zip'
|
|
sha1 '806fc1d91bda82d6a584172d7742531386ae68fb'
|
|
end
|
|
|
|
class ScalaCompletion < Formula
|
|
homepage 'http://www.scala-lang.org/'
|
|
url 'https://raw.github.com/scala/scala-dist/27bc0c25145a83691e3678c7dda602e765e13413/completion.d/2.9.1/scala'
|
|
version '2.9.1'
|
|
sha1 '806fc1d91bda82d6a584172d7742531386ae68fb'
|
|
end
|
|
|
|
class Scala < Formula
|
|
homepage 'http://www.scala-lang.org/'
|
|
url 'http://www.scala-lang.org/downloads/distrib/files/scala-2.9.2.tgz'
|
|
sha1 '806fc1d91bda82d6a584172d7742531386ae68fb'
|
|
|
|
option 'with-docs', 'Also install library documentation'
|
|
|
|
def install
|
|
rm_f Dir["bin/*.bat"]
|
|
doc.install Dir['doc/*']
|
|
man1.install Dir['man/man1/*']
|
|
libexec.install Dir['*']
|
|
bin.install_symlink Dir["#{libexec}/bin/*"]
|
|
ScalaCompletion.new.brew { (prefix/'etc/bash_completion.d').install 'scala' }
|
|
ScalaDocs.new.brew { doc.install Dir['*'] } if build.include? 'with-docs'
|
|
end
|
|
end
|