feat(stepper): add Stepper component #3076
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: Bonk | |
| on: | |
| issue_comment: | |
| types: [created] | |
| pull_request_review_comment: | |
| types: [created] | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.event.issue.number || github.ref }} | |
| cancel-in-progress: false | |
| jobs: | |
| bonk: | |
| if: github.event.sender.type != 'Bot' && (contains(github.event.comment.body, '/bonk') || contains(github.event.comment.body, '@ask-bonk')) | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 60 | |
| permissions: | |
| id-token: write | |
| contents: write | |
| issues: write | |
| pull-requests: write | |
| steps: | |
| - name: Check comment author has repository write access | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| COMMENT_AUTHOR: ${{ github.event.comment.user.login }} | |
| run: | | |
| PERMISSION=$(gh api "repos/$GITHUB_REPOSITORY/collaborators/$COMMENT_AUTHOR/permission" --jq .permission) | |
| case "$PERMISSION" in | |
| admin|maintain|write) ;; | |
| *) echo "::error::Comment author must have repository write access"; exit 1 ;; | |
| esac | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| with: | |
| fetch-depth: 1 | |
| persist-credentials: false | |
| - name: Build prompt with triggering comment | |
| id: prompt | |
| env: | |
| COMMENT_AUTHOR: ${{ github.event.comment.user.login }} | |
| COMMENT_BODY: ${{ github.event.comment.body }} | |
| COMMENT_URL: ${{ github.event.comment.html_url }} | |
| run: | | |
| { | |
| DELIMITER=$(openssl rand -hex 16) | |
| echo "value<<$DELIMITER" | |
| echo "You were invoked by @${COMMENT_AUTHOR} on ${COMMENT_URL}" | |
| echo "" | |
| echo "Their comment:" | |
| echo '```' | |
| echo "$COMMENT_BODY" | |
| echo '```' | |
| echo "" | |
| echo "This is your task. Read it carefully and act on it." | |
| echo "" | |
| echo 'For PR review requests, after checkout, read and follow .github/bonk_reviewer.md from the current PR head, including its final-response Review notes expander. Historical versions read while inspecting the diff are not the active instructions.' | |
| echo 'Apply those review instructions only in review mode; requests to implement a change still require implementation.' | |
| echo "$DELIMITER" | |
| } >> "$GITHUB_OUTPUT" | |
| - name: Run Bonk | |
| uses: Cloudflare-Studio/ask-bonk/github@main | |
| env: | |
| CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CF_AI_GATEWAY_ACCOUNT_ID }} | |
| CLOUDFLARE_GATEWAY_ID: ${{ secrets.CF_AI_GATEWAY_NAME }} | |
| CLOUDFLARE_API_TOKEN: ${{ secrets.CF_AI_GATEWAY_TOKEN }} | |
| OPENCODE_CONFIG_CONTENT: '{"default_agent":"bonk","permission":{"external_directory":{"*":"deny","/home/runner/work/**":"allow"},"question":"deny","doom_loop":"deny"}}' | |
| with: | |
| oidc_base_url: https://ask-bonk.cloudflare-exponent.workers.dev/auth | |
| model: "cloudflare-ai-gateway/openai/gpt-5.6-terra" | |
| variant: "high" | |
| mentions: "/bonk,@ask-bonk" | |
| permissions: write | |
| agent: bonk | |
| opencode_dev: true | |
| opencode_version: "latest" | |
| prompt: ${{ steps.prompt.outputs.value }} |