nix cleanup

This commit is contained in:
Evan Quiney
2025-10-01 09:47:00 +01:00
committed by GitHub
parent 22f0ca2a59
commit b1721e941b
12 changed files with 76 additions and 382 deletions

View File

@@ -1,17 +1,9 @@
import 'just-flake.just'
default:
@just --list
fmt:
uv run ruff format src
lint:
uv run ruff check --fix src
lint-check:
uv run ruff check src
test:
uv run pytest src
@@ -23,33 +15,3 @@ sync:
sync-clean:
uv sync --all-packages --force-reinstall --no-cache
build:
uv build --all-packages
# Build the Go forwarder binary
build-forwarder:
HASH=$(uv run scripts/hashdir.py) && go build -C networking/forwarder -buildvcs=false -o $GO_BUILD_DIR/forwarder -ldflags "-X 'main.SourceHash=${HASH}'"
chmod 0755 $GO_BUILD_DIR/forwarder
# Run forwarder tests
test-forwarder:
cd networking/forwarder && go test ./src/...
# Build all components (Python packages and Go forwarder)
build-all: build build-forwarder
run n="1" clean="false":
@echo "→ Spinning up {{n}} node(s) (clean={{clean}})"
if [ "{{clean}}" = "true" ]; then ./run.sh -c; else ./run.sh; fi
if [ "{{n}}" -gt 1 ]; then \
for i in $(seq 2 "{{n}}"); do \
if [ "{{clean}}" = "true" ]; then ./run.sh -rc; else ./run.sh -r; fi; \
done; \
fi
# remote debugging auto-runner command: TODO: find better place to put this??
# -> this pulls from upstream and wipes .exo folder, rebuilds & restarts
# -> TODO: maybe add a sync step for python deps ??
autorun-master:
uv run scripts/watch-pull-restart.py --cmd "uv run exo-master" --restart-cmd "rm -rf ~/.exo && just build-forwarder"