-
Notifications
You must be signed in to change notification settings - Fork 2
/
kanidm.rb
29 lines (23 loc) · 876 Bytes
/
kanidm.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
class Kanidm < Formula
desc "Kanidm CLI"
version "v1.4.4"
homepage "https://api.github.com/kanidm/kanidm/releases/latest"
url "https://github.com/kanidm/kanidm/archive/refs/tags/#{version}.tar.gz"
sha256 "978e35e2d5fe455b6aef80c49a51bf89e7ba6d4ad0907b38dad2809ae39fff45"
license "Mozilla Public License 2.0"
head "https://github.com/kanidm/kanidm.git", branch: "master"
livecheck do
url :stable
strategy :github_latest
end
depends_on "rust" => :build
def install
system "cargo", "install", "--bin", "kanidm", "--path", "tools/cli", "--locked", "--root", *prefix
# Completion scripts and manpage are generated in the crate's build
# directory, which includes a fingerprint hash. Try to locate it first
out_dir = Dir["target/release/build/kanidm-*/out"].first
end
test do
system "#{bin}/kanidm", "--version"
end
end