diff --git a/.github/workflows/trigger-bitrise.yml b/.github/workflows/trigger-bitrise.yml new file mode 100644 index 00000000..afed1867 --- /dev/null +++ b/.github/workflows/trigger-bitrise.yml @@ -0,0 +1,73 @@ +name: Trigger Bitrise Build + +on: + push: + branches: [main] + paths: + # Only trigger when sample app or dependencies change + - "sample/**" + - "modules/**" + - "package.json" + - "yarn.lock" + - ".github/workflows/trigger-bitrise-build.yml" + + workflow_dispatch: # Allow manual triggers + +jobs: + trigger-bitrise: + name: Trigger Bitrise Build + runs-on: ubuntu-latest + steps: + - name: Trigger Bitrise Pipeline + env: + BITRISE_APP_SLUG: ${{ secrets.BITRISE_APP_SLUG }} + BITRISE_API_TOKEN: ${{ secrets.BITRISE_API_TOKEN }} + run: | + echo "🚀 Triggering Bitrise build for React Native sample app..." + + RESPONSE=$(curl -X POST \ + "https://app.bitrise.io/app/$BITRISE_APP_SLUG/build/start.json" \ + -H "Authorization: token $BITRISE_API_TOKEN" \ + -H "Content-Type: application/json" \ + -d @- <