Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
41 changes: 6 additions & 35 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ jobs:
entitlements-plist-path: src-tauri/entitlements.plist
artifact-name: buzz-app-${{ github.run_id }}-${{ github.run_attempt }}-arm64

- name: Verify release DMG and bundled runtime
- name: Verify release DMG
env:
SIGNED_DMG: ${{ steps.codesign.outputs.signed-dmg-path }}
run: |
Expand All @@ -116,23 +116,6 @@ jobs:
xcrun stapler validate "$app"
codesign --display --entitlements :- "$app" > "$RUNNER_TEMP/signed-entitlements.plist"
test "$(/usr/libexec/PlistBuddy -c 'Print :com.apple.security.device.audio-input' "$RUNNER_TEMP/signed-entitlements.plist")" = true || { echo '::error::Signed app is missing microphone entitlement'; exit 1; }
node --input-type=module - "$app/Contents/Resources/agent-runtime" <<'JS'
import { readFileSync, lstatSync } from 'node:fs';
import assert from 'node:assert/strict';
const directory = process.argv[2];
const source = JSON.parse(readFileSync('runtime/agent-runtime.json', 'utf8'));
const manifest = JSON.parse(readFileSync(`${directory}/manifest.json`, 'utf8'));
assert.equal(manifest.version, 2);
assert.deepEqual(manifest.goose, source.goose);
assert.equal(manifest.revision, source.revision);
assert.equal(manifest.target, 'aarch64-apple-darwin');
assert.deepEqual(Object.keys(manifest.files).sort(), [...source.tools].sort());
for (const name of source.tools) {
const path = `${directory}/${name}`;
assert.ok(lstatSync(path).isFile(), `${name} must be a regular file`);
assert.ok(lstatSync(path).mode & 0o111, `${name} must be executable`);
}
JS
- name: Stage release assets and checksums
env:
Expand Down Expand Up @@ -321,20 +304,9 @@ jobs:
- run: pnpm install --frozen-lockfile
- name: Set candidate version
run: node scripts/candidate-version.mjs
# Vendored OpenSSL (Goose runtime) runs Configure with `perl`. In this
# job's bash shell that is Git's MSYS perl, which lacks modules the
# Configure script needs. Use the image's Strawberry Perl instead.
- name: Select Strawberry Perl for vendored OpenSSL
shell: pwsh
run: |
$perl = 'C:\Strawberry\perl\bin\perl.exe'
if (!(Test-Path $perl)) { throw "Strawberry Perl not found at $perl" }
& $perl -MLocale::Maketext::Simple -MIPC::Cmd -e 1
if ($LASTEXITCODE -ne 0) { throw 'Strawberry Perl lacks OpenSSL Configure modules' }
"OPENSSL_SRC_PERL=$perl" >> $env:GITHUB_ENV
- name: Build NSIS installer
run: pnpm tauri build --ci --no-sign --bundles nsis --config "$RUNNER_TEMP/candidate.json" -- --locked
- name: Install into disposable runner and verify resource payload
- name: Install into disposable runner and verify app executable
shell: pwsh
run: |
$installers = @(Get-ChildItem target/release/bundle/nsis/*.exe)
Expand All @@ -344,8 +316,6 @@ jobs:
$process = Start-Process $installers[0].FullName -ArgumentList "/S /D=$destination" -Wait -PassThru
if ($process.ExitCode -ne 0) { throw "Installer failed: $($process.ExitCode)" }
if (!(Test-Path "$destination\buzz-foundation.exe")) { throw 'App executable missing' }
node scripts/verify-runtime-bundle.mjs "$destination\agent-runtime" x86_64-pc-windows-msvc
if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
- name: Stage candidate and checksum
run: |
mkdir release-assets
Expand Down Expand Up @@ -403,19 +373,20 @@ jobs:
run: node scripts/candidate-version.mjs
- name: Build deb and AppImage
run: pnpm tauri build --ci --no-sign --bundles deb,appimage --config "$RUNNER_TEMP/candidate.json" -- --locked
- name: Repair AppImage and verify both packaged resource payloads
- name: Repair AppImage and verify packaged app executables
run: |
shopt -s nullglob
debs=(target/release/bundle/deb/*.deb)
images=(target/release/bundle/appimage/*.AppImage)
test "${#debs[@]}" -eq 1 && test "${#images[@]}" -eq 1
bash scripts/fix-appimage.sh "${images[0]}"
dpkg-deb -x "${debs[0]}" "$RUNNER_TEMP/deb"
node scripts/verify-runtime-bundle.mjs "$RUNNER_TEMP/deb/usr/lib/Buzz Foundation/agent-runtime" x86_64-unknown-linux-gnu
test -x "$RUNNER_TEMP/deb/usr/bin/buzz-foundation"
image=$(realpath "${images[0]}")
mkdir "$RUNNER_TEMP/appimage"
(cd "$RUNNER_TEMP/appimage" && "$image" --appimage-extract >/dev/null)
node scripts/verify-runtime-bundle.mjs "$RUNNER_TEMP/appimage/squashfs-root/usr/lib/Buzz Foundation/agent-runtime" x86_64-unknown-linux-gnu
test -x "$RUNNER_TEMP/appimage/squashfs-root/usr/bin/buzz-foundation"
test -x "$RUNNER_TEMP/appimage/squashfs-root/usr/bin/buzz-foundation.bin"
mkdir release-assets
cp "${debs[0]}" "release-assets/Buzz_${VERSION}_amd64.deb"
cp "${images[0]}" "release-assets/Buzz_${VERSION}_x86_64.AppImage"
Expand Down
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ coverage/
dist-author/
dist-plugins/

# Generated immutable agent runtime resources.
# Leftover generated v1 runtime resources from older checkouts.
src-tauri/resources/agent-runtime/*
!src-tauri/resources/agent-runtime/README.md
dist-buzz-mcp/
Loading
Loading