Skip to content

YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context

release-app

Louis Beaumont083e9d7bc950
diff --git a/.github/workflows/release-app.yml b/.github/workflows/release-app.yml
index 94168f122..600e9dcb6 100644
--- a/.github/workflows/release-app.yml
+++ b/.github/workflows/release-app.yml
@@ -103,8 +103,29 @@ jobs:
command: release draft ${{ secrets.CN_APP_SLUG }} --framework tauri
api-key: ${{ secrets.CN_API_KEY }}
+ check_runner:
+ runs-on: ubuntu-latest
+ outputs:
+ runner_type: ${{ steps.check.outputs.runner_type }}
+ steps:
+ - id: check
+ run: |
+ # Try to ping self-hosted runner for 2 minutes
+ timeout=120
+ start_time=$SECONDS
+ while [ $(( SECONDS - start_time )) -lt $timeout ]; do
+ if curl -s "${{ github.api_url }}/repos/${{ github.repository }}/actions/runners" \
+ -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" | \
+ jq -e '.runners[] | select(.name | contains("self-hosted")) | select(.status=="online")' > /dev/null; then
+ echo "runner_type=[self-hosted, Windows, X64]" >> $GITHUB_OUTPUT
+ exit 0
+ fi
+ sleep 10
+ done
+ echo "runner_type=windows-latest" >> $GITHUB_OUTPUT
+
publish-tauri:
- needs: [check_commit, draft]
+ needs: [check_commit, draft, check_runner]
if: github.event_name == 'workflow_dispatch' || needs.check_commit.outputs.should_release == 'true'
permissions:
contents: write
@@ -112,17 +133,17 @@ jobs:
fail-fast: false
matrix:
include:
- - platform: "macos-latest" # for Arm based macs (M1 and above).
+ - platform: "macos-latest"
args: "--target aarch64-apple-darwin --features metal,beta"
target: aarch64-apple-darwin
tauri-args: "--target aarch64-apple-darwin"
- - platform: "macos-latest" # for Intel based macs.
+ - platform: "macos-latest"
args: "--target x86_64-apple-darwin --features metal,beta"
target: x86_64-apple-darwin
tauri-args: "--target x86_64-apple-darwin"
- - platform: [self-hosted, Windows, X64] # Windows x86_64
- args: "--target x86_64-pc-windows-msvc --features mkl" # TODO CUDA --features "openblas"
- pre-build-args: "" # --openblas
+ - platform: ${{ needs.check_runner.outputs.runner_type }}
+ args: "--target x86_64-pc-windows-msvc --features mkl"
+ pre-build-args: ""
tauri-args: "--target x86_64-pc-windows-msvc"
runs-on: ${{ matrix.platform }}