# Spec To Issue

> |

- **Type:** Skill
- **Install:** `agentstack add skill-anyoneanderson-agent-skills-spec-to-issue`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [anyoneanderson](https://agentstack.voostack.com/s/anyoneanderson)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [anyoneanderson](https://github.com/anyoneanderson)
- **Source:** https://github.com/anyoneanderson/agent-skills/tree/main/skills/spec-to-issue

## Install

```sh
agentstack add skill-anyoneanderson-agent-skills-spec-to-issue
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# spec-to-issue — Spec to GitHub Issue

Auto-generate GitHub Issues from spec directories (`.specs/{feature}/`).

## Language Rules

1. **Auto-detect input language** → output in the same language
2. Japanese input → Japanese issue, use `references/issue-template.ja.md` as template reference
3. English input → English issue, use `references/issue-template.md` as template reference
4. Explicit override takes priority

**Reference file selection**: Based on the detected output language, use the corresponding template:
- English → `references/issue-template.md`
- Japanese → `references/issue-template.ja.md`

## Execution Flow

### 1. Locate Spec Directory

**With argument**: `spec-to-issue auth-feature` → use `.specs/auth-feature/`

**Without argument**: Scan `.specs/` and present a list → ask user to select

```
Spec directories found in .specs/:
1. auth-feature (requirement.md, design.md, tasks.md)
2. member-management (requirement.md, tasks.md)
Which spec do you want to create an issue from?
```

### 2. File Validation

Required: `requirement.md` must exist. Otherwise, exit with error.
Recommended: `tasks.md` (if missing, generate a basic checklist)
Optional: `design.md` (used as supplementary info if present)

### 3. Spec Analysis

Extract from each file:

**requirement.md:**
- Title: First `# ` line, strip suffixes like "Requirements", "要件定義書"
- Overview: `## Overview` or `## 概要` section
- Key features: Sections starting with `### 1.`, `### 2.`, etc.
- Tech stack: `## Technology Stack` or `## 技術要件` section

**tasks.md:**
- Phases: Lines starting with `## Phase` or `## フェーズ`
- Tasks: `### ` headings within each phase, simplified for checklist
- Done criteria: `## Definition of Done` or `## 完了の定義` section
- Notes: `## Notes` or `## 注意事項` section

**design.md (optional):**
- Architecture overview (as supplementary info)

### 4. Resolve Project Settings

Determine defaults in this priority order:

```
Command arguments > .specs/.config.yml > CLAUDE.md > Built-in defaults
```

**From CLAUDE.md:**
- Branch name: PR target branch from Git Workflow section → `--branch` default
- GitHub Organization: Inferred from repository URL

**.specs/.config.yml (optional):**
```yaml
default-branch: develop
default-labels: [feature, spec-generated]
project-number: 7
assignee: username
```

### 5. Compose Issue Body

See template details in the appropriate reference file (based on Language Rules):
- English: [references/issue-template.md](references/issue-template.md)
- Japanese: [references/issue-template.ja.md](references/issue-template.ja.md)

### 6. Create Issue

**Without --preview (default)**: Show a brief summary and execute `gh issue create`

```
Creating Issue:
  Title: [Feature] Member Management
  Labels: feature, spec-generated
  Phases: 3
  Tasks: 12
→ Running gh issue create...
Issue #42 created: https://github.com/org/repo/issues/42
```

**With --preview**: Display the full issue body, confirm, then execute

### 7. Additional Actions (optional)

- `--label`: Apply specified labels
- `--project`: Add to GitHub Project board via `gh project item-add`
- `--assignee`: Set assignee

## Options

| Option | Description | Default |
|--------|-------------|---------|
| `--preview` | Display issue body for confirmation | OFF |
| `--label ` | Comma-separated labels | `.config.yml` value or none |
| `--project ` | Add to GitHub Project | `.config.yml` value or none |
| `--branch ` | Base branch for spec links | CLAUDE.md or `main` |
| `--assignee ` | Set assignee | `.config.yml` value or none |

## Integration with spec-generator

After spec-generator's `full` phase completes, suggest:

```
All three spec documents have been generated.
→ Create a GitHub Issue from them? (Y/n)
```

If yes, run spec-to-issue on the same directory.

## Error Handling

| Situation | Response |
|-----------|----------|
| `.specs/` does not exist | Error: Spec directory not found |
| `requirement.md` missing | Error: requirement.md is required |
| `tasks.md` missing | Warning: Use basic checklist as fallback |
| `gh` CLI not authenticated | Error: Guide user to `gh auth login` |
| Section not found | Use default value, show warning |

## Usage Examples

```
# With argument
/spec-to-issue auth-feature

# Auto-detect and select
/spec-to-issue

# With preview
/spec-to-issue auth-feature --preview

# With labels and Project
/spec-to-issue auth-feature --label "feature,priority:high" --project 7

# After spec-generator
"Create full spec for todo-app" → done → "Turn this into an issue"

# Japanese
「仕様書を全部作って」→ 完了 →「これをIssueにして」
```

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [anyoneanderson](https://github.com/anyoneanderson)
- **Source:** [anyoneanderson/agent-skills](https://github.com/anyoneanderson/agent-skills)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-anyoneanderson-agent-skills-spec-to-issue
- Seller: https://agentstack.voostack.com/s/anyoneanderson
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
