-
Notifications
You must be signed in to change notification settings - Fork 1
/
justfile
46 lines (34 loc) · 1.02 KB
/
justfile
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
# requires `just`: cargo install just # https://github.com/casey/just
default:
just --list
alias t := test
alias c := check
# Build a wheel with maturin
build:
poetry run maturin build --release
# Builds a wheel with maturin and installs it to the current virtualenv
develop:
poetry run maturin develop --release
# Builds the wheel, installs it, and runs pytest. Then runs rust API tests.
test: develop
HYPOTHESIS_PROFILE=dev pytest
cargo test
# Builds the wheel, installs it, and runs the benchmarks against biopython
bench: develop
python benchmarks/bench.py
# Builds the wheel, installs it, and runs cargo-flamegraph to generate flamegraph.svg
profile: develop
flamegraph python benchmarks/bench.py --no-compare
# Runs fmt, clippy, and black
check: fmt clippy black
# Runs cargo fmt to format Rust code
fmt:
cargo fmt --all
# Runs clippy to lint Rust code
clippy:
cargo clippy --all
# Runs black to format Python code
black:
poetry run black --check .
pytest: develop
poetry run pytest