Skip to content

The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.

refactor: remove manual upload-cli make target and npm script to enforce CI-only releases

0xken1521c720d24556
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 432d5e7dd..a6045ac02 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -27,7 +27,8 @@ name: Release
#
# cli/scripts/upload-cli.sh is used EXACTLY as it is, with no flag this file invented: GCS_BUCKET,
# METADATA_PATH and OTA_KEY are env overrides it already supports. The script is the production
-# release path — `make upload-cli` runs the same bytes from a laptop — and CI adapts to it.
+# release path, and this workflow is its only caller: there is no `make` target that runs it from a
+# laptop, so every published CLI version has the tag that names it.
#
# The TAG is the version. CI never auto-bumps: left to itself the script reads the current version
# out of the remote manifest and adds one, so what publishes would depend on when the job ran.
diff --git a/Makefile b/Makefile
index 2f6dfa5ac..a0b9988de 100644
--- a/Makefile
+++ b/Makefile
@@ -2,9 +2,9 @@
#
# Pass extra arguments to a target's script via ARGS, e.g.:
# make install-cli ARGS="--no-restart"
-# make upload-cli ARGS="0.1.0"
+# make release-cli ARGS="--dry-run"
-.PHONY: cli-test install-cli upload-cli upload-cli-install-sh release-cli release-backend release-desktop remote-machine upload-circle device-test
+.PHONY: cli-test install-cli upload-cli-install-sh release-cli release-backend release-desktop remote-machine upload-circle device-test
## cli-test: typecheck + run the CLI test suite.
cli-test:
@@ -38,16 +38,11 @@ release-desktop:
install-cli:
bash cli/scripts/install-cli.sh $(ARGS)
-## upload-cli: bump version -> bundle -> publish the CLI. MAINTAINER ONLY — it writes to the release
-## bucket, so it needs an authenticated `gcloud storage` with write access on it, plus
-## node/npm for the bundle step.
-## Running daemons pick the new version up within ~1 min.
-upload-cli:
- bash cli/scripts/upload-cli.sh $(ARGS)
-
## upload-cli-install-sh: publish cli/scripts/install.sh — the `curl ... | bash` installer — to
## harness/cli/install.sh in the release bucket (-> https://cdn.autonomous.ai/harness/cli/install.sh).
-## One static file, no version; MAINTAINER ONLY, same credential as upload-cli. Verify the CDN edge
+## One static file, no version; MAINTAINER ONLY (an authenticated `gcloud storage` with write access
+## on the bucket). The CLI bundle itself is never published from a laptop: `make release-cli` tags,
+## and CI runs cli/scripts/upload-cli.sh from the tag (.github/workflows/release.yml). Verify the CDN edge
## serves the new bytes afterwards (the script prints the command).
upload-cli-install-sh:
bash cli/scripts/upload-install-sh.sh
diff --git a/cli/RELEASE.md b/cli/RELEASE.md
index d7e90331b..c3c700feb 100644
--- a/cli/RELEASE.md
+++ b/cli/RELEASE.md
@@ -21,35 +21,28 @@ touches are git and a public HTTPS read of the manifest. See [`../docs/cicd.md`]
what the release workflow itself does, step by step.
**Why the version comes from two places.** `cli/scripts/release-cli.sh` takes the highest of the last
-git tag and the version published under the `cli` key of `harness/cli/metadata.json`. Publishing by
-hand (`make upload-cli`, below) bumps from the manifest and tags nothing, so the two can drift — a
-maintainer who runs it, or a scratch publish that slipped, leaves the manifest ahead of the last tag.
-Bumping from tags alone there would produce a version LOWER than what's already served — every daemon
-refuses it (`shouldUpdate` / `semverGt` in `src/lib/selfUpdate.ts`) while the release still reports
-success.
+git tag and the version published under the `cli` key of `harness/cli/metadata.json`. The two can
+drift — a scratch publish that slipped, or a manifest edited by hand, leaves the manifest ahead of the
+last tag. Bumping from tags alone there would produce a version LOWER than what's already served —
+every daemon refuses it (`shouldUpdate` / `semverGt` in `src/lib/selfUpdate.ts`) while the release
+still reports success.
Unlike `autonomous-harness-desktop`'s `make release`, there is no `--minor` flag: `shouldUpdate` is a
plain "strictly newer" check with no major/minor-triggers-a-forced-update concept, so every release
just needs to outrank what's live.
`package.json`'s `version` field is never touched by this script; the published version is baked into
-the bundle via `ADAPTER_VERSION` at build time (see `make upload-cli` below).
+the bundle via `ADAPTER_VERSION` at build time (see "The publishing step" below).
-## Publishing by hand
+## The publishing step
-`cli/scripts/upload-cli.sh` is the publishing step. CI invokes it with the version taken from the tag;
-it's also reachable directly when CI cannot be:
+`cli/scripts/upload-cli.sh` is the publishing step, and CI is its only caller: `release.yml` runs it
+with the version taken from the tag. There is deliberately no `make` target for it — publishing from a
+laptop created no git tag and bumped from the remote manifest, so the repo stopped reflecting what was
+served, and a stale local tag then broke the next `make release-cli` at `git fetch --tags`. If CI is
+down, fix CI; a version with no tag is worse than a late one.
-```bash
-make upload-cli # auto-bump (0.1.2 -> 0.1.3; 0.1.99 -> 0.2.1)
-make upload-cli ARGS="0.2.0" # explicit version
-make upload-cli ARGS="--no-bump" # rebuild and re-upload the current version
-make upload-cli ARGS="--no-build" # upload the existing dist/ artifact as-is
-```
-
-**This creates no git tag.** It bumps from the remote manifest, so the repo stops reflecting what's
-published. Prefer `make release-cli`; if you do publish by hand, cut a `make release-cli` afterwards to bring
-the tag back in line.
+What the script does, for reading the workflow:
1. Reads the current version from the live manifest (falling back to `package.json` if the manifest is
unreadable), then bumps or takes the version it was given.
diff --git a/cli/package.json b/cli/package.json
index c549294b1..a61eadc83 100644
--- a/cli/package.json
+++ b/cli/package.json
@@ -19,8 +19,7 @@
"test:remote-viewers": "vitest run --config vitest.viewer.config.ts",
"test:cursor-e2e": "RUN_CURSOR_E2E=1 vitest run src/engines/cursor/localE2e.spec.ts",
"test:tmux-real": "RUN_REAL_TMUX_DISCOVERY=1 vitest run src/lib/tmuxAgentDiscovery.real.spec.ts --reporter=verbose",
- "test:herdr-real": "RUN_REAL_HERDR=1 vitest run src/lib/herdrBackend.real.spec.ts --reporter=verbose",
- "release": "bash scripts/upload-cli.sh"
+ "test:herdr-real": "RUN_REAL_HERDR=1 vitest run src/lib/herdrBackend.real.spec.ts --reporter=verbose"
},
"dependencies": {
"@noble/ciphers": "^1.3.0",