-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathjustfile
More file actions
48 lines (38 loc) · 1.03 KB
/
justfile
File metadata and controls
48 lines (38 loc) · 1.03 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
set dotenv-load := true
pdk := env('pdk', 'qpdk')
cpus := num_cpus()
import 'tests/test.just'
import 'docs/docs.just'
# List available commands
default:
@just --list
# Install the package and all development dependencies
[group('setup')]
install:
@uv sync --all-extras
# Install KLayout technology files for the PDK
[group('setup')]
install-tech:
@uv run --dev {{ pdk }}/install_tech.py
# Clean up all build, test, coverage and Python artifacts
[confirm]
[group('setup')]
clean:
@rm -rf dist build *.egg-info docs/_build docs/notebooks
# Update pre-commit hooks to the latest revisions
[group('lint')]
update-pre:
@uvx prek autoupdate -j $(( {{ cpus }} / 2 + {{ cpus }} % 2 ))
# Run all pre-commit hooks on all files
[group('lint')]
run-pre:
uvx prek run --all-files
# Build the Python package (install build tool and create dist)
[group('build')]
build:
@rm -rf dist
uv build
# Run all tests, pre-commit hooks, build wheel and documentation in parallel
[group('all')]
[parallel]
all: test run-pre build docs