From bd24586113ff3bf5abfdaef080c082549b74e3f7 Mon Sep 17 00:00:00 2001 From: andwati Date: Wed, 12 Aug 2026 14:54:58 +0300 Subject: [PATCH] Publish separate extension-only zip alongside source archive Chrome requires manifest.json at the zip root for Web Store submission and manual unpacked loading. The whole-repo git archive added for the native-host installer buried it under extension/, so publish both: a manifest-at-root extension zip and the full-repo source zip. --- .github/workflows/release.yml | 20 +++++++++++++++----- README.md | 15 ++++++++++++--- 2 files changed, 27 insertions(+), 8 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 36e5040..85dde20 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -15,15 +15,25 @@ jobs: - name: Checkout uses: actions/checkout@v4 + - name: Package extension + # Chrome requires manifest.json at the zip root, both for Web Store + # upload and for manually loading unpacked -- so this one archives + # only extension/'s contents, not the whole repo. + run: | + cd extension + zip -r "../kget-capture-extension-${GITHUB_REF_NAME}.zip" . + - name: Package source - # Users need the whole repo (install.sh, native-host/, keys/), not - # just extension/ -- the extension itself now ships via the Chrome - # Web Store. git archive only includes tracked files, so the - # gitignored private key (never committed) can't end up in it. + # Separately, the native-host installer bundle (install.sh, + # native-host/, keys/) needs the whole repo. git archive only + # includes tracked files, so the gitignored private key (never + # committed) can't end up in it. run: git archive --format=zip -o "kget-capture-${GITHUB_REF_NAME}.zip" HEAD - name: Create release uses: softprops/action-gh-release@v2 with: - files: kget-capture-${{ github.ref_name }}.zip + files: | + kget-capture-${{ github.ref_name }}.zip + kget-capture-extension-${{ github.ref_name }}.zip generate_release_notes: true diff --git a/README.md b/README.md index 66af2ef..88e650b 100644 --- a/README.md +++ b/README.md @@ -50,7 +50,8 @@ without them.) 1. Install the extension from the Chrome Web Store: **``** *(placeholder, fill in once the listing is live)*. 2. Install the native messaging host that lets the extension talk to KGet. - Download and extract the latest release from the + Download and extract `kget-capture-vX.Y.Z.zip` (the source archive, not + `kget-capture-extension-vX.Y.Z.zip`) from the [Releases page](https://github.com/andwati/kget-capture/releases), then from inside that folder: ```bash @@ -76,9 +77,17 @@ cd kget-capture ./install.sh ``` +(Or, for an already-tagged version without cloning: download and extract +`kget-capture-extension-vX.Y.Z.zip` from the +[Releases page](https://github.com/andwati/kget-capture/releases) instead. +It's already just `extension/`'s contents, unpacked at the zip root the way +Chrome expects. You'll still need `kget-capture-vX.Y.Z.zip` for `install.sh`, +per step 2 above.) + Then in `chrome://extensions`: enable **Developer mode**, click **Load -unpacked**, and select this repo's `extension/` directory. `install.sh` -prints the extension's fixed ID so you can confirm it loaded correctly. +unpacked**, and select the `extension/` directory (from your clone, or the +extracted extension zip). `install.sh` prints the extension's fixed ID so +you can confirm it loaded correctly. ## Usage