aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/groovyserv.rb
blob: d8ca52c34c9e2a08425632fb5af79300cda40a7b (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
require 'formula'

class Groovyserv < Formula
  homepage 'http://kobo.github.com/groovyserv/'
  url 'https://github.com/downloads/kobo/groovyserv/groovyserv-0.9-src.zip'
  sha1 '54464608f90a381b44cf7959136e1b1f31a3919c'
  head 'https://github.com/kobo/groovyserv.git', :using => :git

  depends_on 'gradle' => :build
  depends_on 'groovy'

  def install
    system 'gradle clean executables'

    prefix.install %w{LICENSE.txt README.txt NOTICE.txt}

    # Install executables in libexec to avoid conflicts
    libexec.install Dir["build/executables/{bin,lib}"]

    # Remove windows files
    rm_f Dir["#{libexec}/bin/*.bat"]

    # Symlink binaries
    bin.install_symlink Dir["#{libexec}/bin/*"]
  end
end