Repository navigation
feat: publish the global edition of MiniMax Code (agent.minimax.io) - #4
Closed
tylerdotai wants to merge 1 commit into
Closed
tylerdotai wants to merge 1 commit into
tylerdotai wants to merge 1 commit into
Conversation
MiniMax ships two separate desktop apps with different backends, accounts, bundle ids and UI languages: cn agent.minimax.cn com.minimax.agent.cn locale zh overseas agent.minimax.io com.minimax.agent locale en The published packages were the CN edition only, so anyone on agent.minimax.io had no Linux package to install. The upstream payload is per-edition (app.asar carries a different .env.local), and packaging/resolve-version.sh already knew how to pick between the two DMGs -- but nothing ever set MMX_REGION, so the default (cn) was the only edition that was ever built. - MMX_REGION selects an edition profile: app id, package name, install prefix, desktop entry, icon name, deep-link scheme, electron-updater manifest and release-tag prefix. Each edition gets its own package identity, so the two can be installed side by side instead of overwriting each other. - install.sh verifies that the extracted payload really is the requested edition (NEXT_PUBLIC_DOMAIN_URL in the payload's .env.local) and fails the build on a mismatch, instead of shipping a package that quietly talks to the wrong backend. build-info.json now records region/domain. - The icon tree is staged under the package's own name so the two editions never claim the same files. - The desktop entry registers only the deep-link scheme the edition uses (the payload derives it from the locale). - resolve-version.sh's electron-updater fallback pointed at a path that 404s; it now uses the edition's -prod manifest (200 for both editions). - The workflow builds both editions and publishes minimax-code-v<version> and minimax-code-global-v<version>; a manual run can build one or both. - 5 new offline test cases. - README: document both editions, and correct the claim that packages are built for both architectures (only x86-64 is built). Verified: 31/31 offline tests; the global edition built from the official global DMG, packaged as .deb/.rpm, and starts on Linux (outcome: ready).
Author
|
Closing this in favour of a single consolidated issue (#6) — four findings in one place, so there is one thing to read and reply to rather than three overlapping PRs. The work is not lost: the branch is still up in the fork and I will open a PR for any part of it you want. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Publish the global edition of MiniMax Code (
agent.minimax.io) next to theCN edition (
agent.minimax.cn).Why
MiniMax ships two separate desktop apps, with different backends, accounts,
bundle ids and UI languages. The packages published here are the CN edition
only. From the published
minimax-code_3.1.4_amd64.deb:So anyone on
agent.minimax.iowho installs the released package gets theChinese edition talking to the CN backend — and there is no global package to
install instead.
Upstream publishes both editions (their download config exposes
cnX64MacosDownloadUrl→filecdn.minimax.chatandoverseasX64MacosDownloadUrl→file.cdn.minimax.io), andpackaging/resolve-version.shalready knew how to choose between them — butnothing ever set
MMX_REGION, so the default (cn) was the only edition thatwas ever built.
Changes
scripts/lib_common.sh—MMX_REGION(cn|overseas) selects anedition profile: app id, package name, install prefix, desktop entry, icon
name, deep-link scheme, electron-updater manifest and release-tag prefix.
Each edition gets its own package identity, so both can be installed side by
side instead of overwriting each other.
install.sh— verify that the extracted payload really is the requestededition (read
NEXT_PUBLIC_DOMAIN_URLfrom the payload's.env.local) andfail the build on a mismatch, instead of shipping a package that quietly
talks to the wrong backend.
build-info.jsonnow recordsregion/domain.packaging/build.sh— stage the icon tree under the package's own name,so the two editions never claim the same files.
packaging/templates/desktop.tmpl— register only the deep-link schemethe edition actually uses (
minimax-cnvsminimax); the payload derives itfrom the locale.
packaging/resolve-version.sh— the electron-updater fallback pointed at…/minimax-agent/release, which 404s; it now uses the edition's-prodmanifest (verified 200 for both editions).
.github/workflows/build.yml— build both editions (matrix) and publishminimax-code-v<version>andminimax-code-global-v<version>. A manual runcan build one edition or both, and takes a DMG URL per edition.
tests/run.sh,tests/fixtures/fake_asar— 5 new cases: each editionbuilds with its own identity, a payload from the other edition is refused,
the per-edition profile is checked, an unknown region is rejected.
README.md— document both editions. Also corrects the claim thatpackages are built "for both architectures": only x86-64 is built today
(
resolve_archrejects anything else) — see the arm64 issue.Verification
tests/run.sh→ 31 passed, 0 failed (26 before, +5 new).file.cdn.minimax.io):payload edition OK: https://agent.minimax.iobuild-info.json→"region": "overseas","app_id": "com.minimax.agent"package.jsonname →minimax-code-global"outcome":"ready") on Linuxminimax-code-global_3.1.4_amd64.debandminimax-code-global-3.1.4.x86_64.rpm, with/opt/minimax-code-global,/usr/bin/minimax-code-global,minimax-code-global.desktop(Icon=minimax-code-global,StartupWMClass=minimax-code-global,MimeType=x-scheme-handler/minimax;)minimax-code-global.png— no file clash with the CNpackage, so both can be installed side by side
asset names as before.
Note
This touches
.github/workflows/build.yml, which #2 and #3 also touch — happyto rebase on top of whichever lands first.