Feat: add POSIX-lite bootstrap foundation

This commit is contained in:
MangoPig
2026-06-21 21:02:59 +01:00
parent 626ae02df0
commit 5735e3008d
14 changed files with 385 additions and 10 deletions

View File

@@ -9,10 +9,14 @@ migrate-up:
migrate-down:
cd '{{backend_dir}}' && go run ./cmd/migrate down
# Reset all embedded database migrations and reapply from scratch.
# Reset all embedded database migrations.
migrate-reset:
cd '{{backend_dir}}' && go run ./cmd/migrate reset
# Reset embedded database migrations and apply them again from scratch.
migrate-rebuild:
cd '{{backend_dir}}' && go run ./cmd/migrate reset && go run ./cmd/migrate up
# Show the embedded database migration status.
migrate-status:
cd '{{backend_dir}}' && go run ./cmd/migrate status
@@ -20,7 +24,3 @@ migrate-status:
# Format backend Go source files.
fmt:
cd '{{backend_dir}}' && gofmt -w ./cmd ./db ./internal
# Run backend test suite.
test:
cd '{{backend_dir}}' && go test ./...

View File

@@ -0,0 +1,11 @@
project_root := justfile_directory()
backend_dir := project_root + "/Backend"
# Run the full backend test suite.
[default]
all:
cd '{{backend_dir}}' && go test ./...
# Run the isolated POSIX bootstrap smoke test.
posix-bootstrap:
cd '{{backend_dir}}' && go test ./internal/bootstrap -run TestEnsureBootstrapPOSIXSkeletonInitializesEmptyRoot -count=1 -v

1
Commands/Test/mod.just Normal file
View File

@@ -0,0 +1 @@
mod backend