In Docker, Settings › About on the Daily channel said "0.1.4479 is out
… docker pull ghcr.io/yetone/magpie:latest". :latest is the newest
release (docker.yml), daily and stable the Daily and Stable channels'
(docker-daily.yml, docker-stable.yml), so :latest held 0.1.4504, not the
0.1.4479 announced; on Stable it is weeks apart. docker.yml writes every
release's own tag (ghcr.io/yetone/magpie:0.1.4479; checked on ghcr: 4479,
4395, latest, daily, stable, 0.1 all resolve, daily = 4479's digest).
update.Image(version) is that tag, and every place that printed the
command names it now, with "recreate the container from it" (a compose
file on :latest would otherwise run the old tag again):
- the GUI's Version row and Update pill (/api/update's new `image`,
stuck "container"; app.js updateStuck);
- `magpie update` in a container (internal/cli);
- a Remote magpie row's tip for a container: UpdateRemotes now keeps the
version it asked for on an "unsupported" answer too, so the tip names
that version's image;
- i18n zh, zh-TW, ja, de for both strings;
- docs/docker (en, zh, ja): Updates says Settings › About names the
version's own image and that latest may be ahead of the channel;
llms-full and search indexes rebuilt (site/docs-index.mjs).
Run at this tree (mica, through mica-run):
- red on origin/main 14b6b9555 with the new tests copied in:
TestUpdateInContainerSaysPullTheImage (cli: ":latest" in the error),
TestRemoteMagpieAskedToFollow (gateway: Version v0.1.100, not the asked
v0.1.200), update-stuck.test.cjs container cases and
remote-update.test.cjs, both engines;
- green here: go test ./internal/update ./internal/cli, internal/gateway
and internal/provider -run TestRemote*, internal/gui except
TestGatewayModeListsNoOwnSessions, which fails the same on
14b6b9555 alone (#7064);
- go vet ./..., GOOS=linux go vet -tags nogui ./..., GOOS=windows go vet
./..., go build, gofmt -l (nothing);
- node --test site/docker-tags.test.mjs; GUI files in chromium and
webkit: update-stuck, remote-update, update-channel,
update-stable-newest, update-release-page, update-check, lan-docker,
i18n-keys, gui-de, gui-zh-tw, i18n-en-no-cjk (216 pass, 0 fail);
gui-ja's "ja has every zh string" is red on main for another string
(#7144).
Not run before the push: the full `go test -tags nogui ./...` (mote and
mica each had another session's full suite running); it runs after.
Not tried: a real container pulling the new tag. Not checked at runtime:
whether the version's image is already on ghcr; docker.yml pushes it in
~6 minutes, before the release is published, and a missing one makes
docker pull fail with "manifest unknown", not pull another version.
The root held 89 .go files (30 commands, 59 tests). They move as they are
to internal/cli (package cli), with git mv so history follows them. The
only code change is main() becoming cli.Main(version): the root's new
main.go keeps `var version` in package main, so -ldflags "-X
main.version=…" in the Makefile, the Dockerfile and magpie-releases, and
every workflow, work unchanged. go-winres's rsrc_windows_*.syso still land
next to package main in the root.
Tests that read testdata by a root-relative path now go up one level
(../plugin/testdata/fake, ../sessions/testdata). Five subsystem doc links
point at internal/cli/.
Run:
- go build ./..., gofmt -l, go vet on darwin, linux and windows (nogui)
- builds with tags production, dev, "production nogui"; windows
-H windowsgui; linux CGO_ENABLED=0
- make release-cli TARGETS="darwin/arm64 linux/amd64 windows/amd64
android/arm64" VERSION=9.9.9-tidy: all four built, binary prints
"magpie 9.9.9-tidy"
- docker build --build-arg VERSION=7.7.7-tidy: container prints
"magpie 7.7.7-tidy"
- go test ./internal/cli (default and nogui): 152 tests, the same count
as the root on main
- go test ./...: all packages pass (agent, gateway, library, provider
timed out at 10m under other sessions' load and passed rerun alone
with -timeout 40m; none of them changed)
- the built binary in a sandbox HOME: version, help, ls, providers,
claude, and an unknown command's error