carlos / todomvc-bakeoff Public
build(ocaml): deploy ships the built version without prompting
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 file changed,
+5
−2
apps/ocaml/Makefile+5 −2
diff --git a/apps/ocaml/Makefile b/apps/ocaml/Makefile| index 500a5a0..117ef10 100644 |
| --- a/apps/ocaml/Makefile |
| +++ b/apps/ocaml/Makefile |
| @@ -1,7 +1,7 @@ |
| # todo-ocaml: TodoMVC for the CARLOS bakeoff. See README.md. |
| SHELL := /bin/bash |
| VERSION ?= $(shell git rev-parse --short HEAD 2>/dev/null || echo dev) |
| -MESSAGE ?= Deploy todo-ocaml $(VERSION) |
| +MESSAGE ?= Deploy todo-ocaml |
| CSS := static/base.css static/index.css |
| DUNE := dune build --root . --profile release |
| @@ -19,6 +19,7 @@ build-arm64: $(CSS) |
| APP_VERSION=$(VERSION) LINK_FLAGS='-ccopt -static' \ |
| tools/arm64.sh $(DUNE) --build-dir $(CURDIR)/_build/arm64 ./bin/main.exe |
| mkdir -p dist && install -m 755 _build/arm64/default/bin/main.exe dist/app-linux-arm64 |
| + echo $(VERSION) > dist/app-linux-arm64.version |
| test: $(CSS) |
| tools/x86.sh dune test --root . --build-dir $(CURDIR)/_build/x86 --force |
| @@ -38,5 +39,7 @@ bump: |
| unbump: |
| sed -i 's/^let build_marker = "todomvc-bumped"$$/let build_marker = "todomvc"/' src/app.ml |
| +# Ships the version the binary was built with, which it reports at /api/version. |
| deploy: |
| - carlos deploy --account bfj --app todo-ocaml --target linux-arm64 --message "$(MESSAGE)" dist/app-linux-arm64 |
| + carlos deploy --account bfj --app todo-ocaml --target linux-arm64 --no-prompt \ |
| + --version "$$(cat dist/app-linux-arm64.version)" --message "$(MESSAGE)" dist/app-linux-arm64 |