-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathjustfile
More file actions
120 lines (99 loc) · 2.93 KB
/
Copy pathjustfile
File metadata and controls
120 lines (99 loc) · 2.93 KB
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
alias a := audit
alias c := check
alias f := fmt
alias cr := example-client-regtest
alias cs := example-client-signet
alias l := lock
alias t := test
alias sc := shellcheck
alias z := zizmor
alias p := pre-push
stable := `cargo rbmt toolchains --stable`
export RBMT_LOG_LEVEL := env("RBMT_LOG_LEVEL", "progress")
_default:
@echo "> bdk-floresta"
@echo "> A Floresta-powered chain-source crate for BDK\n"
@just --list
[doc: "Audit dependencies"]
audit:
@echo "Auditing Cargo.lock"
cargo generate-lockfile
cargo audit --file Cargo.lock
@echo "\nAuditing Cargo-maximum.lock"
cargo audit --file Cargo-maximum.lock
@echo "\nAuditing Cargo-recent.lock"
cargo audit --file Cargo-recent.lock
@echo "\nAuditing Cargo-minimal.lock"
cargo audit --file Cargo-minimal.lock
[doc: "Assert Commit Bisectability"]
bisectability baseline="master":
cargo rbmt run --baseline "{{ baseline }}" -- build --quiet
[doc: "Generate Code Coverage"]
[env("CARGO_LLVM_COV_SETUP", "yes")]
coverage:
cargo +{{ stable }} llvm-cov \
--all-features \
--html \
--ignore-filename-regex '(^|/)test[.]rs$'
cargo +{{ stable }} llvm-cov report \
--lcov \
--output-path target/llvm-cov/lcov.info \
--ignore-filename-regex '(^|/)test[.]rs$'
[doc: "Check Formatting, Linting and Documentation"]
check:
cargo rbmt fmt --check
cargo rbmt lint
cargo rbmt docs
[doc: "Generate Documentation"]
docs:
cargo rbmt docs
[doc: "Generate and Open Documentation"]
docs-open:
cargo rbmt docs --open
[doc: "Run the Regtest Client Example"]
[env("BLOCKS", "25")]
[env("RBMT_LOG_LEVEL", "verbose")]
example-client-regtest:
rm -rf examples/data/client_regtest
cargo rbmt run -- run --release --example client_regtest
[doc: "Run the Signet Client Example"]
[env("RBMT_LOG_LEVEL", "verbose")]
example-client-signet:
rm -rf examples/data/client_signet
cargo rbmt run -- run --release --example client_signet
[doc: "Format Code"]
fmt:
cargo rbmt fmt
[doc: "Regenerate Lockfiles"]
lock:
cargo rbmt lock --lockfiles minimal,recent,maximum
[doc: "Run Tests"]
[env("RBMT_LOG_LEVEL", "verbose")]
test:
cargo rbmt test --toolchain stable --lockfile recent
cargo rbmt test --toolchain stable --lockfile minimal
cargo rbmt test --toolchain msrv --lockfile minimal
[doc: "Update Stable and Nightly Toolchains"]
toolchains:
cargo rbmt toolchains --update-stable
cargo rbmt toolchains --update-nightly
[doc: "Install cargo-rbmt Tools"]
tools:
cargo rbmt tools
cargo rbmt tools --update
[doc: "Run ShellCheck"]
shellcheck:
@command -v shellcheck >/dev/null 2>&1 || { echo "shellcheck was not found on \$PATH" && exit 1; }
find . -name '*.sh' -print -exec shellcheck {} +
[doc: "Run Zizmor"]
zizmor:
zizmor .
[doc: "Run pre-push checks"]
pre-push:
@just lock
@just check
@just docs
@just test
@just shellcheck
@just zizmor
@just audit