Skip to content

Commit

Permalink
Squashed commit of the following:
Browse files Browse the repository at this point in the history
commit 88dae4ea573d8dab70c3d856316dd27fe0ef7e68
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 13:08:44 2024 +1100

    main branch too

commit 370e5c370f536414287773aeb33fe3aaf014cf36
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 13:04:42 2024 +1100

    Documented Windows and Linux release planning for Beyond Better DUI

    Applied changes from BB to 1 file

    Files modified:
    - docs/development/windows_linux_release_planning.md

commit affa89ca32dd48d4102df6f3cd544d208439aedb
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 13:04:18 2024 +1100

    Added macOS entitlements configuration to Tauri config

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit 05e156ae5c3b6f9e3b54eced4ea152033e84d9ab
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 13:04:12 2024 +1100

    Added entitlements for macOS app to enable file access, network access, executing user-selected binaries, and running JIT-compiled code.

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/macos/entitlements.plist

commit 4d78360289f555e5c3e7b987914dadaf05da4e68
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 13:04:01 2024 +1100

    docs: Add macOS release process documentation

    Applied changes from BB to 1 file

    Files modified:
    - docs/development/macos_release_process.md

commit 9c68a1a061a8ba7e55c83c3927e777b293451cca
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 13:01:36 2024 +1100

    Updated the macOS release workflow to build and release DUI for both Apple Silicon and Intel architectures.

    Applied changes from BB to 1 file

    Files modified:
    - .github/workflows/dui-macos-release.yml

commit 998763a0aa9e6939252cda51d8b7f0cd9f413728
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 13:01:01 2024 +1100

    Updated Tauri configuration with new product name, version, and build settings

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit a152b115f444e94d271a18a81439be02f29ecf14
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 13:00:32 2024 +1100

    Added macOS release workflow for DUI

    Applied changes from BB to 1 file

    Files modified:
    - .github/workflows/dui-macos-release.yml

commit 120e3f40283193f8890048bf2d37a7ecb85f5164
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 13:00:11 2024 +1100

    Updated tauri.conf.json with new product name, version, and build configuration.

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit 20f15df3a1815a01faa223444f29912f65b6b1c3
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:58:29 2024 +1100

    Updated Tauri configuration with new product name and version

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit cbf76c4ee4604ccdbd50638a39580f1629b5898b
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:58:16 2024 +1100

    Updated localization strings for Beyond Better DUI installer

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/windows/locales/en-US.wxl

commit 4fc6c8aaa4af41479e93c159e569e0c43e77e517
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:57:58 2024 +1100

    Updated tauri.conf.json with product name, version, and build configuration.

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit fea85b52082e2ae8e64b1374ad863e9b58d00018
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:55:45 2024 +1100

    Updated Tauri configuration with new product name, version, and build settings.

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit beb3f8655a8743f510b68fb5898b8fcff5644fbb
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:55:02 2024 +1100

    Updated tauri.conf.json with version 0.4.1 and build configuration

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit b5c15f2e0003788c90e52ce427df4463dc49829a
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:54:21 2024 +1100

    Updated Tauri configuration with new product name, version, and build settings.

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit b8b566d832422c01030c84bef0c5052027f2bfd6
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:53:07 2024 +1100

    Updated tauri.conf.json with new product name and version

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit 98f60f72f2219e8a4ccd7edae82d9e7446585706
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:52:48 2024 +1100

    Simplified Windows installer configuration in tauri.conf.json

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit 211a8e50c813d1c0a9034bc478c8ce2d111c135a
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:51:11 2024 +1100

    Updated the DUI release workflow to build and publish releases for multiple platforms.

    Applied changes from BB to 1 file

    Files modified:
    - .github/workflows/dui-release.yml

commit 596780eec5961bb3478b815a7c5a06c1f4e83cbe
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:50:54 2024 +1100

    Added registry fragment and component references to tauri.conf.json

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/tauri.conf.json

commit c9b47cfc2b476d803082d8709d821ddd20c924fb
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:50:36 2024 +1100

    Added registry entries for application registration, information, and first-run path update.

    Applied changes from BB to 1 file

    Files modified:
    - dui/src-tauri/windows/fragments/registry.wxs

commit 91070f6af2dfa486d932082224cfe7154e4bad14
Author: Charlie Garrison <[email protected]>
Date:   Sat Dec 7 12:39:08 2024 +1100

    deploy config for v2
  • Loading branch information
cngarrison committed Dec 7, 2024
1 parent 9e9923e commit 1b368f3
Show file tree
Hide file tree
Showing 8 changed files with 602 additions and 16 deletions.
28 changes: 14 additions & 14 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,32 +22,32 @@ jobs:
run: |
mkdir -p .bb
cat << EOF > .bb/config.yaml
version: 2.0.0
myPersonsName: bb
myAssistantsName: Claude
noBrowser: false
bbExeName: bb
bbApiExeName: bb-api
api:
environment: local
apiHostname: localhost
apiPort: 3000
apiUseTls: false
hostname: localhost
port: 3162
ignoreLLMRequestCache: false
usePromptCaching: true
tls:
useTls: false
logFile: api.log
logLevel: info
anthropicApiKey: >-
sk-not-a-valid-key-not-a-valid-key-not-a-valid-key-not-a-valid-key-not-a-valid-key
llmKeys:
anthropic: >-
sk-not-a-valid-key-not-a-valid-key-not-a-valid-key-not-a-valid-key-not-a-valid-key
bui:
environment: local
buiHostname: localhost
buiPort: 8000
buiUseTls: false
hostname: localhost
port: 8000
tls:
useTls: false
cli: {}
repoInfo:
ctagsAutoGenerate: false
tokenLimit: 1024
project:
name: bb
type: git
EOF
- name: Build site
Expand Down
183 changes: 183 additions & 0 deletions .github/workflows/dui-macos-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,183 @@
name: "DUI macOS Release"

on:
push:
branches: ["main","release-build-testing"]
workflow_dispatch:
inputs:
version:
description: 'Version to release'
required: true
default: '0.0.0'

jobs:
build-macos:
permissions:
contents: write
strategy:
fail-fast: false
matrix:
include:
- target: "aarch64-apple-darwin"
arch: "aarch64"
name: "Apple Silicon"
- target: "x86_64-apple-darwin"
arch: "x86_64"
name: "Intel"
runs-on: macos-latest
steps:
- uses: actions/checkout@v4

- name: Setup Deno
uses: denoland/setup-deno@v1
with:
deno-version: v2.x

- name: Install Rust stable
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}

- name: Rust cache
uses: swatinem/rust-cache@v2
with:
workspaces: './dui/src-tauri -> target'

- name: Install frontend dependencies
run: |
cd dui
deno task build
- name: Build DUI (Tauri)
uses: tauri-apps/tauri-action@v0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
projectPath: './dui'
args: --target ${{ matrix.target }}

# Verify build artifacts exist
- name: Verify build artifacts
id: verify_artifacts
run: |
DMG_COUNT=$(find dui/src-tauri/target/${{ matrix.target }}/release/bundle/dmg -name "*.dmg" | wc -l)
APP_COUNT=$(find dui/src-tauri/target/${{ matrix.target }}/release/bundle/macos -name "*.app" | wc -l)
if [ "$DMG_COUNT" -eq 0 ] || [ "$APP_COUNT" -eq 0 ]; then
echo "::error::Missing build artifacts for ${{ matrix.name }} (${{ matrix.target }})"
exit 1
fi
echo "Found $DMG_COUNT .dmg and $APP_COUNT .app files"
# Upload artifacts for both architectures
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: dui-macos-${{ matrix.arch }}
path: |
dui/src-tauri/target/${{ matrix.target }}/release/bundle/dmg/*.dmg
dui/src-tauri/target/${{ matrix.target }}/release/bundle/macos/*.app
# Create release with all artifacts
release:
needs: build-macos
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Get version from config
id: get_version
run: |
CONFIG_VERSION=$(cat dui/src-tauri/tauri.conf.json | jq -r .version)
echo "CONFIG_VERSION=$CONFIG_VERSION" >> $GITHUB_OUTPUT
# If triggered by workflow_dispatch, verify version matches
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
if [[ "$CONFIG_VERSION" != "${{ github.event.inputs.version }}" ]]; then
echo "::error::Version mismatch: $CONFIG_VERSION (config) != ${{ github.event.inputs.version }} (input)"
exit 1
fi
fi
- name: Download all artifacts
uses: actions/download-artifact@v4

- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: dui-v${{ steps.get_version.outputs.CONFIG_VERSION }}
release_name: "Beyond Better DUI v${{ steps.get_version.outputs.CONFIG_VERSION }}"
body: |
Beyond Better DUI v${{ steps.get_version.outputs.CONFIG_VERSION }}
This release includes:
- macOS .app bundles:
* Apple Silicon (M1/M2) version
* Intel version
- macOS disk images (.dmg):
* Apple Silicon (M1/M2) version
* Intel version
Installation:
1. Download the appropriate version for your Mac
2. Open the .dmg file
3. Drag the Beyond Better app to your Applications folder
draft: true
prerelease: false

- name: Upload Release Assets
run: |
# Function to handle upload with retry
upload_asset() {
local file="$1"
local attempt=1
local max_attempts=3
while [ $attempt -le $max_attempts ]; do
echo "Uploading $file (attempt $attempt of $max_attempts)"
if gh release upload "dui-v${{ steps.get_version.outputs.CONFIG_VERSION }}" "$file"; then
return 0
fi
attempt=$((attempt + 1))
if [ $attempt -le $max_attempts ]; then
echo "Retrying in 5 seconds..."
sleep 5
fi
done
echo "::error::Failed to upload $file after $max_attempts attempts"
return 1
}
for arch in x86_64 aarch64; do
case $arch in
"x86_64") arch_name="intel" ;;
"aarch64") arch_name="apple-silicon" ;;
esac
cd "dui-macos-$arch"
# Upload DMG files
for f in *.dmg; do
if [ -f "$f" ]; then
new_name="BB-dui-${{ steps.get_version.outputs.CONFIG_VERSION }}-macos-$arch_name.dmg"
cp "$f" "../$new_name"
upload_asset "../$new_name"
fi
done
# Create and upload app archive
for app in *.app; do
if [ -d "$app" ]; then
new_name="BB-dui-${{ steps.get_version.outputs.CONFIG_VERSION }}-macos-$arch_name.app.tar.gz"
tar -czf "../$new_name" "$app"
upload_asset "../$new_name"
fi
done
cd ..
done
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
95 changes: 95 additions & 0 deletions docs/development/macos_release_process.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
# macOS Release Process

This document describes the process for building and releasing the Beyond Better DUI for macOS.

## Overview

The DUI (Desktop User Interface) is built using Tauri and supports both Intel (x86_64) and Apple Silicon (aarch64) architectures. The release process is automated through GitHub Actions.

## Release Assets

Each release includes:
- `.app` bundles (archived as `.tar.gz`)
* Intel (x86_64) version
* Apple Silicon (aarch64) version
- `.dmg` disk images
* Intel (x86_64) version
* Apple Silicon (aarch64) version

## Build Configuration

The build configuration is defined in `dui/src-tauri/tauri.conf.json` and includes:
- DMG installer window layout
- Minimum macOS version (10.13)
- Required entitlements
- Icon configurations

## Release Process

### Automated Release (GitHub Actions)

1. Trigger a release by either:
- Pushing to the `release` branch
- Using the "DUI macOS Release" workflow manually with a version number

2. The workflow will:
- Build for both Intel and Apple Silicon
- Create `.app` bundles and `.dmg` installers
- Create a draft release
- Upload all assets with architecture-specific names

### Manual Release Steps

If needed, you can build locally using:
```bash
cd dui
# For Intel Macs
deno task tauri build --target x86_64-apple-darwin

# For Apple Silicon Macs
deno task tauri build --target aarch64-apple-darwin
```

## Asset Naming Convention

Release assets follow this naming pattern:
- `BB-dui-{version}-macos-intel.dmg`
- `BB-dui-{version}-macos-intel.app.tar.gz`
- `BB-dui-{version}-macos-apple-silicon.dmg`
- `BB-dui-{version}-macos-apple-silicon.app.tar.gz`

## Version Management

- The version number is managed in `dui/src-tauri/tauri.conf.json`
- When using manual workflow triggers, the input version must match the config
- Git tags are created in the format `dui-v{version}`

## Requirements

### Build Environment
- macOS machine (for local builds)
- Xcode Command Line Tools
- Rust with appropriate targets
- Deno

### Signing and Notarization
- Apple Developer account (for future signing implementation)
- Developer certificate
- App-specific password for notarization

## Future Enhancements

1. Code Signing
- Implementation pending Apple Developer account
- Will require additional workflow secrets
- Will enable notarization

2. Notarization
- To be implemented after signing
- Required for distribution outside App Store
- Will add additional build time

3. App Store Distribution
- Future consideration
- Will require additional configuration
- Separate distribution process
Loading

0 comments on commit 1b368f3

Please sign in to comment.