speckit-init

$npx mdskill add github/spec-kit-copilot/speckit-init

Scaffold a Spec Kit project for GitHub Copilot using specify init.

  • Bootstraps spec-driven development in a new or existing repository.
  • Requires the Specify CLI (specify) available in the shell.
  • Always runs specify init with Copilot integration in skills mode.
  • Installs spec-kit commands as Copilot Agent Skills in .github/skills.

SKILL.md

.github/skills/speckit-initView on GitHub ↗
---
name: speckit-init
description: 'Scaffold a Spec Kit (spec-driven development) project for GitHub Copilot by running `specify init --integration copilot --integration-options="--skills"`. USE FOR: starting a new spec-kit project, bootstrapping spec-driven development in an existing repo, installing spec-kit templates/scripts/commands for Copilot. DO NOT USE FOR: managing extensions/presets/bundles of an already-initialized project (use the speckit-extension / speckit-preset / speckit-bundle skills instead).'
argument-hint: 'project name (or "." / --here for current directory)'
---

# Spec Kit — init

Initialize a spec-driven development project for **GitHub Copilot** with the
**Specify CLI** (`specify`). This skill exposes the `specify init` command. You (the
agent) run the CLI on the user's behalf via the shell; the CLI does the scaffolding.

Because this is the Copilot plugin, **always** scaffold Copilot in **skills mode**:

```
--integration copilot --integration-options="--skills"
```

This installs spec-kit commands (and any extensions added later) as Copilot
**Agent Skills** — `.github/skills/speckit-<cmd>/SKILL.md` — rather than the default
`.github/agents/*.agent.md` layout. Skills are what Copilot CLI discovers as `SKILL.md`,
so this keeps the project consistent with how this plugin works. Do not omit
`--integration-options="--skills"`.

## Prerequisite

This skill needs the `specify` CLI. Confirm it is available:

```bash
specify --version
```

If it is missing (`command not found`), use the **speckit-cli-setup** skill to install
it first, then continue.

## When to use

- The user wants to start a **new** spec-kit project.
- The user wants to add spec-driven development to the **current** directory.

## How to invoke

`specify init` scaffolds templates, scripts, the spec-kit workflow, shared
infrastructure, and the Copilot command files. It runs offline from assets
bundled in the installed CLI.

Common forms (always Copilot + skills mode). Pick the `--script` flavor for the
user's OS — `sh` on **macOS/Linux**, `ps` on **Windows** (the examples below use
`sh`; swap in `--script ps` on Windows):

```bash
# New project directory
specify init <project-name> --integration copilot --integration-options="--skills" --script sh

# Initialize in the current directory
specify init . --integration copilot --integration-options="--skills" --script sh
specify init --here --integration copilot --integration-options="--skills" --script sh

# Current directory is non-empty: skip the confirmation prompt
specify init --here --integration copilot --integration-options="--skills" --script sh --force

# Install a preset at init time
specify init <project-name> --integration copilot --integration-options="--skills" --script sh --preset healthcare-compliance
```

On Windows, use `--script ps` instead:

```powershell
specify init <project-name> --integration copilot --integration-options="--skills" --script ps
```

### Key options

- `--integration copilot` — always use this in the Copilot plugin.
- `--integration-options="--skills"` — **required**; scaffolds spec-kit commands as Copilot Agent Skills (`SKILL.md`) instead of `.agent.md` files.
- `--script <sh|ps|py>` — choose the helper script flavor. **Always pass this when
  running `specify init` for the user.** When stdin is a TTY — which the agent shell
  allocates — omitting `--script` opens an interactive "Choose script type" chooser that
  blocks the command. (With genuinely non-interactive stdin, e.g. a closed pipe, the CLI
  instead auto-selects the OS default, but you can't rely on that from a PTY-backed agent
  session.) Use `sh` on **macOS/Linux**, `ps` on **Windows**; `py` is a cross-platform
  Python fallback.
- `--ignore-agent-tools` — skip checks for the agent's CLI tools. **Recommended** for the
  Copilot plugin so init doesn't fail on missing external agent CLIs.
- `--here` / `.` — initialize in the current directory instead of creating a new one.
- `--force` — skip the confirmation when `--here` targets a non-empty directory.
- `--preset <id>` — install a preset during initialization.

## Notes

- Prefer non-interactive flags so the command does not block on prompts.
- **Always pass `--script`** (`sh` on macOS/Linux, `ps` on Windows, `py` anywhere).
  When `specify init` runs with a TTY on stdin — as it does in a PTY-backed agent
  session — omitting `--script` opens an interactive "Choose script type" chooser that
  blocks. (`--integration copilot` already suppresses the *integration* chooser, but the
  *script-type* chooser still appears.) The CLI only auto-selects the OS default when
  stdin is genuinely non-interactive (e.g. a closed pipe), which you can't count on here,
  so this is the most common cause of `specify init` appearing to freeze.
- Always pass both `--integration copilot` and `--integration-options="--skills"`;
  the skills layout is what makes spec-kit commands (and later-added extensions)
  show up as `SKILL.md` for Copilot.
- After init, point the user at the generated skills under `.github/skills/` and the
  `.specify/` directory. Newly generated skills are picked up in the current Copilot
  session with **`/skills reload`**, and automatically on the next session start.
  Suggest `specify check` to verify their environment.

More from github/spec-kit-copilot

SkillDescription
speckit-artifactInspect the effective Spec Kit artifact inventory and composition stacks via `specify artifact`. USE FOR: listing commands/templates/scripts/hooks, explaining which preset or extension layer supplies an artifact, inspecting resolution precedence and hidden layers, checking hook registration, or resolving a stack lookupId to its validated contribution. DO NOT USE FOR: installing or changing presets/extensions (use speckit-preset or speckit-extension), resolving only a preset-managed filename (use speckit-preset), or running an artifact.
speckit-bundleDiscover, install, and author Spec Kit bundles via `specify bundle`. USE FOR: searching/showing/listing bundles, installing/updating/removing a bundle (a curated set of extensions/presets/integrations/workflows), validating a bundle manifest, building a distributable bundle artifact, initializing a project and installing a bundle, managing bundle catalog sources. DO NOT USE FOR: individual extensions/presets/integrations/workflows (use their respective skills).
speckit-checkCheck the local environment for Spec Kit by running `specify check` (and `specify version`). USE FOR: verifying required tools are installed, diagnosing a broken spec-kit setup, reporting CLI version/feature capabilities. DO NOT USE FOR: installing or upgrading the CLI itself (use the speckit-self skill).
speckit-cli-setupDetect and install the Spec Kit `specify` CLI that every other speckit skill depends on. USE FOR: checking whether `specify` is installed/on PATH, installing it when missing, fixing "command not found: specify", confirming the CLI is new enough (>= 0.11). DO NOT USE FOR: upgrading an already-installed CLI to a newer release (use speckit-self) or verifying project tools (use speckit-check).
speckit-extensionManage Spec Kit extensions via `specify extension`. USE FOR: listing installed extensions as text or JSON, installing/removing/updating extensions, searching the extension catalog, showing extension info, enabling/disabling extensions, setting resolution priority, or managing extension catalogs. DO NOT USE FOR: artifact composition stacks (use speckit-artifact), presets (use speckit-preset), bundles (use speckit-bundle), or workflows (use speckit-workflow).
speckit-presetManage Spec Kit presets via `specify preset`. USE FOR: listing installed presets as text or JSON, installing/removing presets, searching the preset catalog, showing preset info, resolving which template a preset name maps to, enabling/disabling presets, setting resolution priority, or managing preset catalogs. DO NOT USE FOR: full artifact composition stacks (use speckit-artifact), extensions (use speckit-extension), bundles (use speckit-bundle), or workflows (use speckit-workflow).
speckit-selfCheck for and apply Spec Kit CLI updates via `specify self`. USE FOR: checking whether a newer specify-cli release is available, previewing an upgrade with --dry-run, upgrading the CLI in place (optionally to a pinned tag). DO NOT USE FOR: checking project tools/integrations (use speckit-check) or managing extensions/presets/integrations/workflows.
speckit-workflowManage and run Spec Kit automation workflows via `specify workflow`. USE FOR: running a workflow by ID or local YAML, resuming a paused/failed run, checking run status, listing/installing/removing workflows, searching the workflow catalog, showing a workflow step graph. DO NOT USE FOR: extensions (use speckit-extension), presets (use speckit-preset), or bundles (use speckit-bundle).
speckit-workflow-stepManage Spec Kit workflow step types via `specify workflow step`. USE FOR: listing built-in and custom workflow step types, installing/removing a custom step type from a catalog, searching/showing step-type info, managing step-type catalog sources. DO NOT USE FOR: running or installing whole workflows (use speckit-workflow), or bundles (use speckit-bundle).