forked from sqreen/PyMiniRacer
-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathJustfile
More file actions
82 lines (62 loc) · 2.48 KB
/
Justfile
File metadata and controls
82 lines (62 loc) · 2.48 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
lint:
uv lock --check
uv run mypy .
uv run ruff format --check
uv run ruff check
npx prettier --check .
uv run mkdocs build --strict
clang-format --style=Chromium -i src/v8_py_frontend/*.cc src/v8_py_frontend/*.h --dry-run -Werror
clang-tidy:
uv run builder/v8_build.py --fetch-only
# Things we're disabling:
# lvmlibc-* is intended for the llvm project itself
# llvm-header-guard is likewise hard-coded for the llvm project itself
# llvm-include-order fights clang-format --style=Chromium
# fuchsia has some odd opinions, so disable it globally.
# altera-* is designed for FPGAs and gives weird performance advice.
# we aren't using Google's absl lib, so disable its suggestions.
clang-tidy \
-checks=*,-llvmlibc-*,-llvm-header-guard,-llvm-include-order,-fuchsia-*,-altera-*,-abseil-* \
-warnings-as-errors=* \
-extra-arg-before=-xc++ \
-extra-arg=-std=c++20 \
-extra-arg=-stdlib=libstdc++ \
-extra-arg=-isystem \
-extra-arg=v8_workspace/v8/include \
-extra-arg=-DV8_ENABLE_SANDBOX \
-extra-arg=-DV8_COMPRESS_POINTERS \
src/v8_py_frontend/*.cc \
src/v8_py_frontend/*.h
fix:
uv lock
uv run ruff format
npx prettier --write .
clang-format --style=Chromium -i src/v8_py_frontend/*.cc src/v8_py_frontend/*.h
serve-docs:
uv run mkdocs serve
deploy-docs:
uv run mkdocs gh-deploy --force
build-dll *args:
# We build v8 outside of the Python packaging system because it's not
# linking with the C Python API (so the Python packaging system doesn't
# provide a lot of value), and the build is very time-consuming and
# fragile, which makes the Python build idioms (including, e.g., uv's
# way of building in a temporary isolated environment every time) very
# awkward.
uv sync --no-install-project
uv run --no-project builder/v8_build.py {{args}}
build-wheel:
uv build
build: build-dll build-wheel
test:
uv run pytest tests
test-matrix *args:
uv run --python 3.10 {{args}} pytest tests
uv run --python 3.11 {{args}} pytest tests
uv run --python 3.12 {{args}} pytest tests
uv run --python 3.13 {{args}} pytest tests
uv run --python 3.14 {{args}} pytest tests
git-config-global:
git config --global core.symlinks true
git config --global user.name 'github-actions[bot]'
git config --global user.email '41898282+github-actions[bot]@users.noreply.github.com'