File tree 1 file changed +34
-0
lines changed
1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change
1
+ class Aptos < Formula
2
+ desc "Layer 1 blockchain built to support fair access to decentralized assets for all"
3
+ homepage "https://aptoslabs.com/"
4
+ url "https://github.com/aptos-labs/aptos-core/archive/refs/tags/aptos-cli-v1.0.3.tar.gz"
5
+ sha256 "670bb6cb841cb8a65294878af9a4f03d4cba2a598ab4550061fed3a4b1fe4e98"
6
+ license "Apache-2.0"
7
+
8
+ livecheck do
9
+ url :stable
10
+ regex ( /^aptos-cli[._-]v?(\d +(?:\. \d +)+)$/i )
11
+ end
12
+
13
+ depends_on "cmake" => :build
14
+ depends_on "rustup-init" => :build
15
+ uses_from_macos "llvm" => :build
16
+
17
+ on_linux do
18
+ depends_on "pkg-config" => :build
19
+ depends_on "openssl@3"
20
+ depends_on "systemd"
21
+ end
22
+
23
+ def install
24
+ system "#{ Formula [ "rustup-init" ] . bin } /rustup-init" ,
25
+ "-qy" , "--no-modify-path" , "--default-toolchain" , "1.64"
26
+ ENV . prepend_path "PATH" , HOMEBREW_CACHE /"cargo_cache/bin"
27
+ system "cargo" , "install" , *std_cargo_args ( path : "crates/aptos" )
28
+ bin . install "target/release/aptos"
29
+ end
30
+
31
+ test do
32
+ assert_match ( /output.pub/i , shell_output ( "#{ bin } /aptos key generate --output-file output" ) )
33
+ end
34
+ end
You can’t perform that action at this time.
0 commit comments