From 87b898211d5f5ef8e310715cd2f6a786877fe479 Mon Sep 17 00:00:00 2001 From: Quantum Explorer Date: Thu, 21 May 2026 03:29:49 +0700 Subject: [PATCH] ci(release): fix dashmate deb pack by configuring oclif targets `oclif pack deb` has no `--targets` flag, so passing it aborts the deb release job with "Nonexistent flag: --targets". Move the linux target selection to `oclif.update.node.targets` in package.json, which the deb (and macos) pack commands read, and drop the `--targets` flag from the deb case. tarballs/win keep their `--targets` overrides since those commands support the flag. Co-Authored-By: Claude Opus 4.7 (1M context) --- packages/dashmate/package.json | 11 +++++++++++ scripts/pack_dashmate.sh | 14 +++++--------- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/packages/dashmate/package.json b/packages/dashmate/package.json index ce27cc60ea7..3ca7252f74a 100644 --- a/packages/dashmate/package.json +++ b/packages/dashmate/package.json @@ -128,6 +128,17 @@ ], "commands": "./src/commands", "bin": "dashmate", + "update": { + "node": { + "targets": [ + "linux-x64", + "linux-arm64", + "win32-x64", + "darwin-x64", + "darwin-arm64" + ] + } + }, "macos": { "identifier": "org.dash.dashmate", "sign": "'Developer ID Installer: The Dash Foundation, Inc.'" diff --git a/scripts/pack_dashmate.sh b/scripts/pack_dashmate.sh index 0a751d49899..063239b7b1d 100755 --- a/scripts/pack_dashmate.sh +++ b/scripts/pack_dashmate.sh @@ -21,19 +21,15 @@ fi FLAGS="" # Node 24+ does not publish 32-bit binaries (linux-armv7l, win-x86), so we -# must explicitly drop those targets from oclif's default lists; otherwise -# `oclif pack` 404s while downloading the embedded Node runtime. -# - tarballs default: oclif builds whatever we pass; we previously passed -# `linux-arm` (= armv7l). Replace with linux-arm64. -# - deb default targets: linux-x64, linux-arm (armv7l), linux-arm64 — drop arm. -# - win default targets: win32-x64, win32-x86 — drop x86. +# must drop those targets from oclif's defaults; otherwise `oclif pack` 404s +# while downloading the embedded Node runtime. +# - `tarballs` and `win` accept `--targets`, so we override on the command line. +# - `oclif pack deb` has no `--targets` flag; its linux targets come from +# `oclif.update.node.targets` in packages/dashmate/package.json. case "$COMMAND" in tarballs) FLAGS="--no-xz --targets=linux-arm64,linux-x64" ;; - deb) - FLAGS="--targets=linux-x64,linux-arm64" - ;; win) FLAGS="--targets=win32-x64" ;;