feat(usage): add pairwise cost comparisons #1139
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Desktop Artifacts | |
| on: | |
| workflow_dispatch: | |
| # Only build the expensive desktop/tauri bundles on the main branch and on | |
| # pull requests targeting main, and only when desktop-relevant files change. | |
| # Stacked PRs that target another feature branch run the test suite via ci.yml | |
| # but skip these multi-platform bundle builds until they reach main. | |
| push: | |
| branches: [main] | |
| paths: | |
| - 'desktop/**' | |
| - 'frontend/**' | |
| - 'go.mod' | |
| - 'go.sum' | |
| - '.github/workflows/desktop-*.yml' | |
| pull_request: | |
| branches: [main] | |
| paths: | |
| - 'desktop/**' | |
| - 'frontend/**' | |
| - 'go.mod' | |
| - 'go.sum' | |
| - '.github/workflows/desktop-*.yml' | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| build: | |
| name: Desktop Build (${{ matrix.name }}) | |
| runs-on: ${{ matrix.os }} | |
| env: | |
| AGENTSVIEW_TARGET_TRIPLE: ${{ matrix.target_triple }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - name: macOS (aarch64) | |
| os: macos-15 | |
| bundle: app | |
| target_triple: aarch64-apple-darwin | |
| artifact_name: agentsview-desktop-macos-aarch64 | |
| artifact_dir: desktop/src-tauri/target/aarch64-apple-darwin/release/bundle/macos/ | |
| - name: macOS (x86_64) | |
| os: macos-15 | |
| bundle: app | |
| target_triple: x86_64-apple-darwin | |
| artifact_name: agentsview-desktop-macos-x86_64 | |
| artifact_dir: desktop/src-tauri/target/x86_64-apple-darwin/release/bundle/macos/ | |
| - name: Windows | |
| os: windows-latest | |
| bundle: nsis | |
| target_triple: "" | |
| artifact_name: agentsview-desktop-windows | |
| artifact_dir: desktop/src-tauri/target/release/bundle/nsis/ | |
| - name: Linux | |
| os: ubuntu-22.04 | |
| bundle: appimage | |
| target_triple: "" | |
| artifact_name: agentsview-desktop-linux | |
| artifact_dir: desktop/src-tauri/target/release/bundle/appimage/ | |
| - name: Linux (arm64) | |
| os: ubuntu-22.04-arm | |
| bundle: appimage | |
| target_triple: aarch64-unknown-linux-gnu | |
| artifact_name: agentsview-desktop-linux-arm64 | |
| artifact_dir: desktop/src-tauri/target/aarch64-unknown-linux-gnu/release/bundle/appimage/ | |
| steps: | |
| - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 | |
| with: | |
| persist-credentials: false | |
| - uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0 | |
| with: | |
| go-version-file: go.mod | |
| - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 | |
| with: | |
| node-version: "24" | |
| - name: Setup MinGW (Windows) | |
| if: runner.os == 'Windows' | |
| uses: msys2/setup-msys2@66cd2cce69caa17b53920067426061ca1de3a884 # v2 | |
| with: | |
| msystem: MINGW64 | |
| update: false | |
| install: mingw-w64-x86_64-gcc | |
| path-type: inherit | |
| - name: Install Linux system dependencies | |
| if: runner.os == 'Linux' | |
| run: | | |
| sudo apt-get update -q | |
| sudo apt-get install -y \ | |
| libwebkit2gtk-4.1-dev libgtk-3-dev \ | |
| libappindicator3-dev librsvg2-dev \ | |
| patchelf squashfs-tools xdg-utils | |
| - name: Install Rust target | |
| if: env.AGENTSVIEW_TARGET_TRIPLE != '' | |
| run: rustup target add "$AGENTSVIEW_TARGET_TRIPLE" | |
| - name: Install desktop dependencies | |
| run: npm ci | |
| working-directory: desktop | |
| - name: Desktop sidecar smoke tests | |
| shell: bash | |
| run: bash desktop/scripts/test-prepare-sidecar.sh | |
| - name: Build desktop bundle | |
| shell: bash | |
| run: | | |
| cd desktop | |
| export TAURI_ENV_TARGET_TRIPLE="$AGENTSVIEW_TARGET_TRIPLE" | |
| npm run prepare-sidecar | |
| build_cmd=(npx tauri build --bundles "${{ matrix.bundle }}") | |
| if [ -n "$AGENTSVIEW_TARGET_TRIPLE" ]; then | |
| build_cmd+=(--target "$AGENTSVIEW_TARGET_TRIPLE") | |
| fi | |
| build_cmd+=(--config '{"bundle":{"createUpdaterArtifacts":false}}') | |
| "${build_cmd[@]}" | |
| if [ "${{ matrix.bundle }}" = "appimage" ]; then | |
| bash scripts/repair-appimage-diricon.sh \ | |
| "../${{ matrix.artifact_dir }}"/*.AppImage | |
| fi | |
| - name: Desktop smoke tests (Rust unit tests) | |
| shell: bash | |
| run: | | |
| test_cmd=(cargo test --manifest-path desktop/src-tauri/Cargo.toml --lib) | |
| if [ -n "$AGENTSVIEW_TARGET_TRIPLE" ]; then | |
| export TAURI_ENV_TARGET_TRIPLE="$AGENTSVIEW_TARGET_TRIPLE" | |
| test_cmd+=(--target "$AGENTSVIEW_TARGET_TRIPLE") | |
| fi | |
| "${test_cmd[@]}" | |
| - name: Smoke check sidecar metadata | |
| shell: bash | |
| run: | | |
| target_triple="${AGENTSVIEW_TARGET_TRIPLE:-$(rustc -vV | awk '/^host: /{print $2}')}" | |
| if [ -z "$target_triple" ]; then | |
| echo "target triple is empty" >&2 | |
| exit 1 | |
| fi | |
| ext="" | |
| if [[ "$target_triple" == *"windows"* ]]; then | |
| ext=".exe" | |
| fi | |
| sidecar="desktop/src-tauri/binaries/agentsview-${target_triple}${ext}" | |
| if [ ! -f "$sidecar" ]; then | |
| echo "missing sidecar binary: $sidecar" >&2 | |
| exit 1 | |
| fi | |
| "$sidecar" version > sidecar-version.txt | |
| if grep -q "agentsview dev" sidecar-version.txt; then | |
| echo "sidecar version should not be dev: $(cat sidecar-version.txt)" >&2 | |
| exit 1 | |
| fi | |
| if grep -q "commit unknown" sidecar-version.txt; then | |
| echo "sidecar metadata missing commit: $(cat sidecar-version.txt)" >&2 | |
| exit 1 | |
| fi | |
| if grep -Eq "built[[:space:]]*\)$" sidecar-version.txt; then | |
| echo "sidecar metadata missing build date: $(cat sidecar-version.txt)" >&2 | |
| exit 1 | |
| fi | |
| - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 | |
| with: | |
| name: ${{ matrix.artifact_name }} | |
| path: ${{ matrix.artifact_dir }} | |
| if-no-files-found: error |