CI: build WebUI and publish node/no-node zips
Simplify CI by removing job matrices and always building the WebUI flavor. Both dev and release workflows now run build:all, verify the websocket native module, and produce two archives: a zero-install bundle that includes node.exe and a no-node variant (requires Node >=22). Artifact names and upload steps were adjusted (dev uses SHA-based names; release uses tag-based names), and release notes were updated to document the two packages and WebUI defaults.
This commit is contained in:
1 parent
8ca616ec3a
commit
b6341145be
2 files changed
+42
-33
No files matched your search
@@ -13,16 +13,6 @@ jobs:
|
||||
permissions:
|
||||
actions: write
|
||||
contents: read
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- name: "standard"
|
||||
script: "build"
|
||||
suffix: ""
|
||||
- name: "webui"
|
||||
script: "build:all"
|
||||
suffix: "-WebUI"
|
||||
steps:
|
||||
- name: Delete old artifacts
|
||||
uses: actions/github-script@v7
|
||||
@@ -66,29 +56,47 @@ jobs:
|
||||
- name: Install dependencies
|
||||
run: pnpm install --frozen-lockfile
|
||||
|
||||
# Always builds the WebUI flavor — no separate "core-only" artifact.
|
||||
- name: Build project
|
||||
run: pnpm run ${{ matrix.script }}
|
||||
run: pnpm run build:all
|
||||
|
||||
- name: Verify native files
|
||||
shell: pwsh
|
||||
run: |
|
||||
if (!(Test-Path "dist\native\snowluma-win32-x64.node")) { throw "Missing dist\native\snowluma-win32-x64.node" }
|
||||
if (!(Test-Path "dist\native\snowluma-win32-x64.dll")) { throw "Missing dist\native\snowluma-win32-x64.dll" }
|
||||
if (!(Test-Path "dist\native\websocket-win32-x64.node")) { throw "Missing dist\native\websocket-win32-x64.node" }
|
||||
|
||||
- name: Bundle runtime dependencies
|
||||
working-directory: dist
|
||||
run: npm install --omit=dev
|
||||
|
||||
- name: Package artifact
|
||||
# Two artifacts:
|
||||
# * SnowLuma-dev.zip – full bundle, ships node.exe (zero-install)
|
||||
# * SnowLuma-dev-no-node.zip – same bundle without node.exe (user provides Node >= 22)
|
||||
- name: Package artifact (no-node)
|
||||
shell: pwsh
|
||||
run: |
|
||||
Compress-Archive -Path "dist\*" -DestinationPath "SnowLuma-dev-no-node.zip"
|
||||
|
||||
- name: Package artifact (with node.exe)
|
||||
shell: pwsh
|
||||
run: |
|
||||
Copy-Item (Get-Command node).Source -Destination "dist\node.exe"
|
||||
Compress-Archive -Path "dist\*" -DestinationPath "SnowLuma-dev${{ matrix.suffix }}.zip"
|
||||
Compress-Archive -Path "dist\*" -DestinationPath "SnowLuma-dev.zip"
|
||||
|
||||
- name: Upload artifact
|
||||
- name: Upload artifact (with node.exe)
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: SnowLuma-dev-${{ github.sha }}${{ matrix.suffix }}
|
||||
path: SnowLuma-dev${{ matrix.suffix }}.zip
|
||||
name: SnowLuma-dev-${{ github.sha }}
|
||||
path: SnowLuma-dev.zip
|
||||
retention-days: 3
|
||||
overwrite: true
|
||||
|
||||
- name: Upload artifact (no-node)
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: SnowLuma-dev-${{ github.sha }}-no-node
|
||||
path: SnowLuma-dev-no-node.zip
|
||||
retention-days: 3
|
||||
overwrite: true
|
||||
Reference in new issue
Block a user