--- name: create-issue description: Create an issue in GitHub or Jira. Automatically detects if GitHub issues are enabled; if so creates a GitHub issue, otherwise creates a Jira issue. allowed-tools: Bash(gh:*), Bash(jira:*), Bash(git:*), Read, Write --- # Create Issue Create an issue in the appropriate tracker (GitHub Issues or Jira). ## Step 1: Detect Issue Tracker 1. **Get repository name**: `basename $(git rev-parse --show-toplevel)` 2. **Check if GitHub issues are enabled**: ```bash gh repo view --json hasIssuesEnabled --jq '.hasIssuesEnabled' ``` - If `true` → Create GitHub issue - If `false` → Create Jira issue 3. **Determine issue type**: Task, Bug, or Story 4. **Check for assignee** in user's request 5. **Determine priority/labels** based on severity --- ## GitHub Issues If GitHub issues are enabled, use `gh issue create`. ### Step 2a: Write issue body to `issue-body.md` Use the appropriate template based on issue type (see Templates section below). **Note:** This file will be deleted after the command runs. ### Step 2b: Run gh command ```bash gh issue create \ --title "" \ --body-file issue-body.md \ --label "