-
Notifications
You must be signed in to change notification settings - Fork 2
/
whatwhat.rb
30 lines (23 loc) · 1001 Bytes
/
whatwhat.rb
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
29
30
class Whatwhat < Formula
desc "`whatwhat` is a command-line tool to report project allocations"
homepage "https://github.com/alan-turing-institute/whatwhat"
url "https://github.com/alan-turing-institute/whatwhat.git", tag: "v0.0.29", revision: "7d77994e19119bbcf8dfb02cfae2b63a50b052f5"
license "MIT"
depends_on "opam" => :build
depends_on "openssl@3"
bottle do
root_url "https://github.com/alan-turing-institute/whatwhat/releases/download/v0.0.29"
sha256 cellar: :any, arm64_ventura: "a2e296b6a14b25de9fa7085010145a18f40bc91558b813a2eb2a68169b654fec"
end
def install
opamroot = buildpath/".opam"
ENV["OPAMROOT"] = opamroot
ENV["OPAMYES"] = "1"
ENV.deparallelize
system "opam", "init", "--no-setup", "--disable-sandboxing"
system "opam", "install", "dune"
system "opam", "exec", "--", "make", "install-deps"
system "mkdir", "-p", "#{ENV["HOME"]}/.config/whatwhat"
bin.install "_build/default/bin/main.exe" => "whatwhat"
end
end