openspec-sync-specs

Merge delta specifications into main OpenSpec spec files.

6.2k|152|Updated Feb 7, 2024
One-click install
npx skills add https://github.com/PBH-BTN/PeerBanHelper --skill openspec-sync-specs-pbh-btn
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: openspec-sync-specs
Source: https://github.com/PBH-BTN/PeerBanHelper/tree/main/.claude/skills/openspec-sync-specs
Command: npx skills add https://github.com/PBH-BTN/PeerBanHelper --skill openspec-sync-specs-pbh-btn

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill automates the synchronization of delta specifications into the main OpenSpec set, enabling seamless propagation of changes without manual re-creation.

Core Features & Use Cases

  • Intelligent delta merging: reads delta specs located under openspec/changes/<change>/specs and merges them into the corresponding main specs, preserving unrelated content.
  • Automatic main spec creation: creates missing main specs at openspec/specs/<capability>/spec.md when needed.
  • Guarded workflow: prompts for change selection when multiple delta changes exist, and requires clarification if delta intent is ambiguous.

Quick Start

  • Ensure the OpenSpec CLI is installed and accessible.
  • List available delta changes: openspec list --json; select the desired change when prompted.
  • The tool reads openspec/changes/<change>/specs/*/spec.md and updates openspec/specs/<capability>/spec.md accordingly.

Frequently Asked Questions about openspec-sync-specs

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I merge delta specs into main OpenSpec specifications?

Delta spec merging applies ADDED, MODIFIED, REMOVED, and RENAMED sections from openspec/changes/<name>/specs into openspec/specs/<capability>/spec.md, preserving existing content. It automates synchronization without manual re-creation.

What happens to existing main spec content when merging delta changes?

Existing main spec content not mentioned in the delta is preserved during merging. The tool only applies ADDED, MODIFIED, REMOVED, and RENAMED sections from the delta specs, keeping unrelated content intact in openspec/specs/<capability>/spec.md.

How do I create missing main specs during a delta merge?

Missing main specs are created automatically at openspec/specs/<capability>/spec.md when needed during the synchronization process. The tool reads delta specs and generates the corresponding main spec files if they do not already exist.

Can I select specific delta changes when multiple specs need merging?

Yes, you can select specific delta changes. The workflow prompts for change selection when multiple delta changes exist by listing available changes, allowing you to choose the desired delta to merge into the main specification set.

What if the intent of my delta spec is ambiguous during the merge?

If the delta intent is ambiguous, the merging process requires clarification before proceeding. This guarded workflow ensures accurate synchronization of your delta specifications into the main OpenSpec set without guessing the intended changes.

Do I need the OpenSpec CLI to synchronize delta specifications?

Yes, you need the OpenSpec CLI installed and accessible to synchronize delta specifications. You list available delta changes using openspec list --json and select the desired change when prompted to update the main specs.