upgrade-rules-v2

Migrate CLAUDE.md from rules v1 to v2 with stack detection.

5|1|Updated Apr 10, 2026
One-click install
npx skills add https://github.com/garethrhughes/fragile --skill upgrade-rules-v2
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: upgrade-rules-v2
Source: https://github.com/garethrhughes/fragile/tree/main/.opencode/skills/upgrade-rules-v2
Command: npx skills add https://github.com/garethrhughes/fragile --skill upgrade-rules-v2

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill upgrades a project from the older rules v1 setup to the newer rules v2 structure, so the repository can use a clean language-agnostic core plus the right stack-specific overlay.

Core Features & Use Cases

  • CLAUDE.md Migration: Inserts the Active Skillset line and updates engineering-rule references to point at both the core rules and the active stack overlay.
  • Stack Detection: Identifies whether the project is TypeScript or .NET by inspecting repository signals before choosing the correct profile.
  • Safe Rule Cleanup: Flags duplicated inline v1 rule sections for manual review instead of deleting user content automatically.
  • Installer Refresh: Re-runs the appropriate agent installer scripts after the migration when project agent directories are present.

Quick Start

Use the upgrade-rules-v2 skill to inspect this repository, determine the active stack, and patch CLAUDE.md for a rules v2 migration.

Frequently Asked Questions about upgrade-rules-v2

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

FAQPage Schema
How do I migrate CLAUDE.md from rules v1 to rules v2?▼

Migrating CLAUDE.md to rules v2 involves inserting the Active Skillset line and updating engineering-rule references to point at both the core rules and the active stack overlay, enabling a clean language-agnostic structure.

Does the rules v2 migration support both TypeScript and .NET stacks?▼

Yes, the rules v2 migration supports TypeScript and .NET stacks by inspecting repository signals to detect the active stack before choosing and applying the correct stack-specific profile overlay.

What is the safest way to clean up duplicated inline rules during a CLAUDE.md upgrade?▼

The safest approach flags duplicated inline v1 rule sections for manual review instead of automatically deleting user content, ensuring your custom rules are preserved during the migration patch.

How do I update agent installer scripts when upgrading to rules v2?▼

When project agent directories are present, the migration process re-runs the appropriate agent installer scripts automatically after patching CLAUDE.md to ensure your OpenCode agents align with the new rules structure.

When do I need to run a rules v2 migration on my OpenCode repository?▼

You need a rules v2 migration when your repository uses OpenCode skills and currently relies on the older rules v1 setup, requiring a one-time upgrade to adopt the language-agnostic core and stack-specific overlay.