ci: find the desktop bundles in CARGO_TARGET_DIR, accept Linux aarch64 in latest.json
CI / Formatação e clippy (push) Successful in 23s
CI / Auditoria de dependências (push) Successful in 25s
CI / Compila o app desktop (Linux) (push) Successful in 1m12s
Release / Cria a release (push) Successful in 5s
CI / Testes (Linux) (push) Successful in 4m20s
Release / CLI (linux-aarch64) (push) Successful in 2m28s
Release / CLI (linux-x86_64) (push) Successful in 2m38s
Release / App desktop (linux) (push) Successful in 11m25s
Release / App desktop (windows) (push) Successful in 11m8s
Release / Monta o latest.json (push) Successful in 6s
CI / Formatação e clippy (push) Successful in 23s
CI / Auditoria de dependências (push) Successful in 25s
CI / Compila o app desktop (Linux) (push) Successful in 1m12s
Release / Cria a release (push) Successful in 5s
CI / Testes (Linux) (push) Successful in 4m20s
Release / CLI (linux-aarch64) (push) Successful in 2m28s
Release / CLI (linux-x86_64) (push) Successful in 2m38s
Release / App desktop (linux) (push) Successful in 11m25s
Release / App desktop (windows) (push) Successful in 11m8s
Release / Monta o latest.json (push) Successful in 6s
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
b47708126e
commit
009c3d61de
5 files changed
+36
-7
No files matched your search
@@ -53,14 +53,14 @@ cd apps/gui/src-tauri
|
||||
case "$platform" in
|
||||
linux)
|
||||
tauri build --bundles appimage,deb
|
||||
bundle=target/release/bundle
|
||||
bundle="${CARGO_TARGET_DIR:-target}/release/bundle"
|
||||
cp "$bundle"/appimage/*.AppImage "$bundle"/deb/*.deb ../../../dist-gui/
|
||||
cp "$bundle"/appimage/*.AppImage.sig ../../../dist-gui/ 2>/dev/null || true
|
||||
;;
|
||||
windows)
|
||||
rustup target add x86_64-pc-windows-msvc >/dev/null
|
||||
tauri build --runner cargo-xwin --target x86_64-pc-windows-msvc --bundles nsis
|
||||
bundle=target/x86_64-pc-windows-msvc/release/bundle/nsis
|
||||
bundle="${CARGO_TARGET_DIR:-target}/x86_64-pc-windows-msvc/release/bundle/nsis"
|
||||
cp "$bundle"/*-setup.exe ../../../dist-gui/
|
||||
cp "$bundle"/*-setup.exe.sig ../../../dist-gui/ 2>/dev/null || true
|
||||
;;
|
||||
|
||||
@@ -18,6 +18,7 @@ from datetime import datetime, timezone
|
||||
# Sem macOS: não há runner para compilar essa plataforma.
|
||||
PLATFORMS = [
|
||||
(["linux-x86_64", "linux-x86_64-appimage"], "Guara_{v}_amd64.AppImage"),
|
||||
(["linux-aarch64", "linux-aarch64-appimage"], "Guara_{v}_aarch64.AppImage"),
|
||||
(["windows-x86_64", "windows-x86_64-nsis"], "Guara_{v}_x64-setup.exe"),
|
||||
]
|
||||
|
||||
@@ -61,10 +62,12 @@ def main():
|
||||
assets[name] = (by_name[name]["browser_download_url"], sig)
|
||||
data = build(version, open(notes_path, encoding="utf-8").read(), assets,
|
||||
datetime.now(timezone.utc).strftime("%Y-%m-%dT%H:%M:%SZ"))
|
||||
# Sem Linux e Windows o atualizador não funciona para ninguém: não publica pela metade.
|
||||
for must in ("linux-x86_64", "windows-x86_64"):
|
||||
if must not in data["platforms"]:
|
||||
sys.exit(f"faltam o pacote ou a assinatura de {must}; confira se TAURI_SIGNING_PRIVATE_KEY está nos segredos")
|
||||
# O CI gera o Linux aarch64 (o runner é arm64); o x86_64 vem de uma máquina x86_64 e
|
||||
# entra depois (scripts/build-gui.sh linux). Exige o Windows e ao menos um Linux.
|
||||
platforms = data["platforms"]
|
||||
if "windows-x86_64" not in platforms or not any(k.startswith("linux-") for k in platforms):
|
||||
sys.exit(f"faltam pacotes ou assinaturas (achei {sorted(platforms)}); "
|
||||
"confira se TAURI_SIGNING_PRIVATE_KEY está nos segredos")
|
||||
with open(out, "w", encoding="utf-8") as f:
|
||||
json.dump(data, f, indent=2, ensure_ascii=False)
|
||||
f.write("\n")
|
||||
|
||||
@@ -22,7 +22,7 @@ class LatestJson(unittest.TestCase):
|
||||
self.assertEqual(d["version"], "1.3.2")
|
||||
self.assertEqual(d["notes"], "### Novidades")
|
||||
p = d["platforms"]
|
||||
for k in ("linux-x86_64", "linux-x86_64-appimage", "windows-x86_64", "windows-x86_64-nsis"):
|
||||
for k in ("linux-x86_64", "linux-x86_64-appimage", "linux-aarch64", "windows-x86_64", "windows-x86_64-nsis"):
|
||||
self.assertIn(k, p)
|
||||
self.assertTrue(p["windows-x86_64"]["url"].endswith("x64-setup.exe"))
|
||||
self.assertEqual(p["linux-x86_64"]["signature"], "assinatura-de-Guara_1.3.2_amd64.AppImage")
|
||||
|
||||
Reference in new issue
Block a user