This commit is contained in:
18
justfile
18
justfile
@@ -10,13 +10,16 @@ formula := "hpa"
|
||||
bottle:
|
||||
@brew uninstall {{formula}} || true
|
||||
@brew tap {{tap}} {{tap_url}}
|
||||
@brew install --build-bottle {{formula}}
|
||||
@brew bottle {{formula}} --json
|
||||
@brew install --build-bottle {{tap}}/{{formula}}
|
||||
@brew bottle {{formula}}
|
||||
bottle="$(ls *.gz)" && mv "${bottle}" "${bottle/--/-}"
|
||||
|
||||
# Build the command-line tool.
|
||||
build mode="debug":
|
||||
swift build -c {{mode}}
|
||||
build configuration="debug" arch="arm64":
|
||||
swift build \
|
||||
--disable-sandbox \
|
||||
--configuration {{configuration}} \
|
||||
--arch {{arch}}
|
||||
|
||||
alias b := build
|
||||
|
||||
@@ -26,11 +29,14 @@ build-docker file="Dockerfile" tag="latest":
|
||||
--file docker/{{file}} \
|
||||
--tag {{docker_image_name}}:{{tag}} .
|
||||
|
||||
build-docker-test: (build-docker "Dockerfile.test" "test")
|
||||
|
||||
# Build the docker test image used for testing.
|
||||
build-docker-test: (build-docker "Dockerfile.test" "test")
|
||||
|
||||
build-universal-binary: (build "release" "arm64") (build "release" "x86_64")
|
||||
@lipo -create -output {{formula}} \
|
||||
".build/arm64-apple-macosx/release/hpa" \
|
||||
".build/x86_64-apple-macosx/release/hpa"
|
||||
|
||||
# Run tests.
|
||||
test *ARGS:
|
||||
swift test {{ARGS}}
|
||||
|
||||
Reference in New Issue
Block a user