Skip to content

Commit 2abb3fb

Browse files
committed
release: fetch chromium-web-store via stable latest/download URL (no API rate limit), non-fatal
1 parent 64aada5 commit 2abb3fb

1 file changed

Lines changed: 8 additions & 5 deletions

File tree

apps/desktop/scripts/build-release.sh

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,17 @@ stage() { # dest dir
2525

2626
# Bundle chromium-web-store so Chrome Web Store installs work on Ungoogled
2727
# Chromium (which disables them by default). Preserves extension compatibility.
28+
# Non-fatal: a download hiccup must not fail the release. Use the stable
29+
# latest/download URL (no GitHub API → no rate limit).
2830
local crx; crx="$(mktemp)"
29-
local url
30-
url="$(curl -fsSL https://api.github.com/repos/NeverDecaf/chromium-web-store/releases/latest \
31-
| grep -oE '"browser_download_url": *"[^"]+\.crx"' | head -1 | sed 's/.*"http/http/;s/"$//')"
32-
if [ -n "$url" ] && curl -fsSL "$url" -o "$crx"; then
31+
local url="https://github.com/NeverDecaf/chromium-web-store/releases/latest/download/Chromium.Web.Store.crx"
32+
if curl -fsSL "$url" -o "$crx" 2>/dev/null; then
3333
mkdir -p "$s/extensions/chromium-web-store"
3434
unzip -q -o "$crx" -d "$s/extensions/chromium-web-store" 2>/dev/null || true
35-
[ -f "$s/extensions/chromium-web-store/manifest.json" ] && echo " + bundled chromium-web-store"
35+
[ -f "$s/extensions/chromium-web-store/manifest.json" ] && echo " + bundled chromium-web-store" \
36+
|| rm -rf "$s/extensions/chromium-web-store"
37+
else
38+
echo " ! chromium-web-store download skipped (non-fatal)"
3639
fi
3740
rm -f "$crx"
3841
}

0 commit comments

Comments
 (0)