-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjustfile
More file actions
73 lines (54 loc) · 1.6 KB
/
justfile
File metadata and controls
73 lines (54 loc) · 1.6 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
# Anki Python Deck Tool - Just Commands
ayt := "uv run anki-yaml-tool"
[private]
default: help
[private]
help:
@just --list --unsorted
update-ayt:
uv pip install -e '/mnt/c/Google Drive/Proyectos/Anki-python-deck-tool'
# Install dependencies
install:
uv pip install -e .
# Install development dependencies
dev:
uv pip install -e ".[dev]"
# Run tests
test:
uv run pytest tests/ -v
# Run linting checks
lint:
uv run ruff check .
# Run linting checks with auto-fix
lint-fix:
uv run ruff check . --fix
# Format code
format:
uv run ruff format .
# Run type checking
type-check:
uv run mypy src --ignore-missing-imports
# Run all checks
all: format lint-fix lint type-check test
# Clean build artifacts
clean:
uv run -c "import shutil, pathlib; [shutil.rmtree(p, ignore_errors=True) for p in ['build', 'dist', *pathlib.Path('.').rglob('*.egg-info'), *pathlib.Path('.').rglob('__pycache__')]]; [p.unlink() for p in pathlib.Path('.').rglob('*.pyc')]"
# Build distribution packages
build:
uv run -m build # FIX
# Build single-file executable
build-exe:
uv run scripts/build.py
# Install executable system-wide (Windows)
[windows]
install-system-wide:
powershell -ExecutionPolicy Bypass -File scripts/install-system-wide.ps1
# Install executable system-wide (Unix)
[unix]
install-system-wide:
bash scripts/install-system-wide.sh
# Build and install executable
build-install: build-exe install-system-wide
# Build, push, and clean example decks
examples: update-ayt
ayt batch-build --input-dir examples --recursive --output-dir "examples/" --push --sync --delete-after