spacehub

surshar / claude-code

Claude Code is an agentic coding tool that lives in your terminal, understands your codebase, and helps you code faster by executing routine tasks, explaining complex code, and handling git workflows - all through natural language commands.

Built by Anthropic · github.com/anthropics

claude-code / .github / workflows / issue-notify.yml
42 lines · 1.3 KBRaw
1name: Issue Notification
2
3on:
4 issues:
5 types: [opened]
6
7permissions:
8 issues: read
9 actions: write
10
11jobs:
12 notify:
13 runs-on: ubuntu-latest
14 timeout-minutes: 5
15 steps:
16 - name: Process new issue
17 env:
18 ISSUE_URL: ${{ github.event.issue.html_url }}
19 ISSUE_NUMBER: ${{ github.event.issue.number }}
20 ISSUE_TITLE: ${{ github.event.issue.title }}
21 TARGET_REPO: ${{ secrets.ISSUE_NOTIFY_TARGET_REPO }}
22 GH_TOKEN: ${{ secrets.ISSUE_NOTIFY_TOKEN || github.token }}
23 run: |
24 # Check if internal processing is configured
25 if [ -z "$TARGET_REPO" ]; then
26 echo "Internal processing not configured"
27 exit 0
28 fi
29
30 echo "Processing issue #${ISSUE_NUMBER}"
31
32 # Trigger internal workflow via repository_dispatch
33 gh api repos/${TARGET_REPO}/dispatches \
34 --method POST \
35 -H "Accept: application/vnd.github.v3+json" \
36 -f event_type="issue-opened" \
37 -f "client_payload[issue_url]=${ISSUE_URL}" 2>/dev/null || {
38 echo "Issue notification sent (dispatch may have failed due to permissions)"
39 exit 0
40 }
41
42 echo "✅ Issue processed and dispatched to ${TARGET_REPO}"