-
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathjustfile
More file actions
103 lines (79 loc) · 2.43 KB
/
justfile
File metadata and controls
103 lines (79 loc) · 2.43 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
set windows-shell := ["powershell.exe", "-NoLogo", "-Command"]
default:
@just --list
# Install all dependencies including dev
install:
uv sync --group dev
# Run the test suite
test:
uv run pytest
# Run tests with verbose output
test-verbose:
uv run pytest -v
# Run tests and open the HTML coverage report
[unix]
coverage:
uv run pytest --cov-report=html
open htmlcov/index.html
[windows]
coverage:
uv run pytest --cov-report=html
Invoke-Item htmlcov/index.html
# Lint with ruff
lint:
uv run ruff check .
# Format code with black
format:
uv run black .
# Check formatting without making changes
format-check:
uv run black --check .
# Type check with ty
type-check:
uv run ty check src/
# Run lint, format, and type checks (used in CI)
check: lint format-check type-check
# Auto-fix lint issues then format with black
fix:
uv run ruff check --fix .
uv run black .
# Build the package
build:
uv build
# Publish the package to PyPI
publish: build
uv publish
# Publish a dev build to TestPyPI (mirrors what CI does on the develop branch)
publish-test: build
uv publish --publish-url https://test.pypi.org/legacy/
# Show the current package version
version:
@uv run python -c "import tomllib; print(tomllib.load(open('pyproject.toml','rb'))['project']['version'])"
# Serve docs locally with live reload
docs:
uv run mkdocs serve
# Build docs site to site/ directory
docs-build:
uv run mkdocs build
# Remove build artifacts
[unix]
clean:
rm -rf dist/ .pytest_cache/ htmlcov/ .coverage coverage.xml
find . -type d -name "__pycache__" -exec rm -rf {} +
find . -type f -name "*.pyc" -delete
[windows]
clean:
Remove-Item -Recurse -Force dist, .pytest_cache, htmlcov, .coverage, coverage.xml -ErrorAction SilentlyContinue
Get-ChildItem -Path . -Recurse -Filter "*.pyc" | Remove-Item -Force -ErrorAction SilentlyContinue
# Run the CLI against a file (usage: just detect path/to/audio.wav)
detect audio model="VIT" dataset="VoxCelebSpoof" vis="ConstantQ":
uv run jabberjay {{ audio }} -m {{ model }} -d {{ dataset }} -vis {{ vis }}
# Run the quickstart example (recommended first step)
example:
uv run python examples/quickstart.py
# Run a specific example (usage: just run-example preloading_audio)
run-example name:
uv run python examples/{{ name }}.py
# Run the exhaustive model sweep (slow — downloads all models)
run-all:
uv run python examples/run_all.py