diff --git a/.github/workflows/android-apk.yml b/.github/workflows/android-apk.yml deleted file mode 100644 index 5a5d0afc6..000000000 --- a/.github/workflows/android-apk.yml +++ /dev/null @@ -1,96 +0,0 @@ -name: Android APK - -# Builds the standalone Pi Mobile APK (apps/mobile/platforms/android). The bundled runtime keeps the monorepo layout -# and runs the workspace packages from source, so it needs their generated model data and the pi-env daemons too. -# apps/ exists only in pi-private; the jobs do nothing elsewhere. -on: - workflow_dispatch: - push: - branches: [private] - paths: - - 'apps/mobile/**' - - 'packages/ai/**' - - 'packages/chord/**' - - 'packages/durable/**' - - 'packages/env/**' - - 'packages/telemetry/**' - - 'packages/coding-agent/src/experimental/source-resolver.ts' - - 'package.json' - - 'package-lock.json' - - 'tsconfig.json' - - 'tsconfig.base.json' - - '.github/workflows/android-apk.yml' - - '.github/workflows/env-daemons.yml' - -permissions: - contents: read - -jobs: - # The daemon for the phone runs terminals; the others serve remote environments. - env-daemons: - if: github.repository == 'earendil-works/pi-private' - uses: ./.github/workflows/env-daemons.yml - permissions: - contents: read - - apk: - needs: env-daemons - runs-on: ubuntu-latest - timeout-minutes: 40 - steps: - - uses: actions/checkout@v5 - - uses: actions/setup-node@v5 - with: - node-version: '26.4.0' - cache: npm - - name: Install host check dependencies without lifecycle scripts - run: npm ci --ignore-scripts - - name: Generate the model data of pi-ai - run: npm run hydrate:model-data - - name: Check the app (host dependencies) - working-directory: apps/mobile - run: npm run check - - name: Fetch the pi-env daemons - uses: actions/download-artifact@v4 - with: - pattern: pi-env-* - path: packages/env/bin - - name: Check the pi-env daemons - run: | - test -s packages/env/bin/pi-env-android-arm64/pi-env - chmod +x packages/env/bin/*/pi-env* - ls -lR packages/env/bin - - uses: actions/setup-java@v5 - with: - distribution: temurin - java-version: '21' - - uses: android-actions/setup-android@v3 - with: - packages: platform-tools - - uses: gradle/actions/setup-gradle@v4 - - name: Install SDK 35 - run: sdkmanager 'platforms;android-35' 'build-tools;35.0.0' - - name: Test Android archive validation - working-directory: apps/mobile - run: node --test test/android-installer.test.ts - - name: Package Termux ARM64 tools and TLS certificates - run: python3 apps/mobile/platforms/android/scripts/package-rootfs.py - - name: Stage Android runtime separately and verify native bindings - run: python3 apps/mobile/platforms/android/scripts/package-runtime.py - - name: Preserve the debug signing key for installable updates - uses: actions/cache@v4 - with: - path: ~/.android/debug.keystore - key: pi-mobile-debug-signing-v1 - - name: Assemble debug APK - working-directory: apps/mobile/platforms/android - run: bash ./gradlew --no-daemon assembleDebug - - uses: actions/upload-artifact@v4 - with: - name: pi-mobile-debug-arm64 - path: | - apps/mobile/platforms/android/app/build/outputs/apk/debug/*.apk - apps/mobile/platforms/android/app/src/main/assets/termux-packages.json - apps/mobile/platforms/android/app/src/main/assets/runtime-version - if-no-files-found: error - retention-days: 14 diff --git a/.husky/pre-commit b/.husky/pre-commit index 64fb972ae..5abf7e5d9 100755 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -16,16 +16,16 @@ if [ $? -ne 0 ]; then exit 1 fi -# Pi Mobile has its own check (own biome.json, TypeScript 5.9; apps/ is outside the root Biome and tsc configs). +# p2 has its own check (own biome.json, TypeScript 5.9; apps/ is outside the root Biome and tsc configs). # apps/ exists only in pi-private. -if [ -d apps/mobile ]; then +if [ -d apps/p2 ]; then for file in $STAGED_FILES; do case "$file" in - apps/mobile/*|packages/*|package.json|package-lock.json|tsconfig.json|tsconfig.base.json) - echo "Checking apps/mobile..." - npm --prefix apps/mobile run check + apps/p2/*|packages/*|package.json|package-lock.json|tsconfig.json|tsconfig.base.json) + echo "Checking apps/p2..." + npm --prefix apps/p2 run check if [ $? -ne 0 ]; then - echo "❌ apps/mobile checks failed." + echo "❌ apps/p2 checks failed." exit 1 fi break