Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

migrate-to-promptscript

БесплатноБез исполняемых скриптовНе проверен

Migrate existing AI instruction files to PromptScript format

diegosouzapwот diegosouzapw★ 68 звёзд на GitHub

Об этом скилле

Migrate to PromptScript

Overview

This skill guides you through migrating existing AI instruction files to PromptScript format, creating a unified source of truth for all AI coding assistants.

Step 1: Discovery

Search for existing instruction files using these patterns:

Claude Code:

  • CLAUDE.md, claude.md, CLAUDE.local.md

Cursor:

  • .cursorrules
  • .cursor/rules/*.md
  • .cursor/rules/*.mdc

GitHub Copilot:

  • .github/copilot-instructions.md
  • .github/instructions/*.md

Other:

  • AGENTS.md
  • AI_INSTRUCTIONS.md
  • AI.md
  • .ai/instructions.md

Use Glob tool to find these files.

Step 2: Read and Analyze

For each discovered file:

  1. Read the full content using the Read tool
  2. Identify sections by headers (##, ###) and patterns
  3. Classify content type using the mapping table below
  4. Note any tool-specific content that may need special handling

Step 3: Content Mapping

Map source content to PromptScript blocks:

Source Pattern PromptScript Block
You are, persona, identity, role @identity
Tech stack, languages, frameworks @context
Coding standards, conventions, rules @standards
Don't, Never, restrictions @restrictions
Commands, shortcuts @shortcuts
API docs, references, knowledge base @knowledge
Parameters, config values @params
File patterns, globs, applyTo @guards
Skills, capabilities @skills
Agents, subagents @agents
Local-only settings @local

Step 4: Generate PromptScript

Required: @meta block

Every PromptScript file needs metadata with id and syntax fields.

Identity (persona)

Convert persona descriptions to @identity block with triple-quote string.

Context (project info)

Convert tech stack to @context block with structured properties like project, languages, frameworks.

Standards (conventions)

Convert coding standards to @standards block organized by category: code, naming, commits, etc.

Restrictions (don'ts)

Convert restrictions to @restrictions block using dash prefix for each item.

Shortcuts (commands)

Convert custom commands to @shortcuts block. Simple shortcuts use key-value format. Complex shortcuts use object format with prompt, description, and content fields.

Knowledge (references)

Convert API docs and reference material to @knowledge block using triple-quote string for rich content.

Guards (file patterns)

Convert file-specific rules to @guards block with globs array specifying file patterns.

Params (configuration)

Convert configuration parameters to @params block with type annotations: range(), enum(), boolean.

Skills (capabilities)

Convert skill definitions to @skills block with description, trigger, and content fields.

Agents (subagents)

Convert agent definitions to @agents block with description, tools, model, and content fields.

Step 5: File Organization

Simple Projects - single file structure:

  • .promptscript/project.prs
  • promptscript.yaml

Complex Projects - modular file structure:

  • .promptscript/project.prs (main with @use imports)
  • .promptscript/context.prs
  • .promptscript/standards.prs
  • .promptscript/restrictions.prs
  • .promptscript/commands.prs
  • promptscript.yaml

Step 6: Configuration

Create promptscript.yaml with:

  • version: '1'
  • project.id
  • input.entry pointing to main .prs file
  • targets for github, claude, cursor

Step 7: Validation

After generating PromptScript files:

  1. Validate syntax: prs validate
  2. Test compilation: prs compile --dry-run
  3. Compare output with original files
  4. Iterate if content is missing or incorrect

Common Patterns

Merging Multiple Sources

When instructions exist in multiple files:

  1. Identity: Take from most detailed source
  2. Standards: Merge all, deduplicate
  3. Restrictions: Combine all (union)
  4. Commands: Merge, resolve conflicts

Tool-Specific Content

Handle tool-specific content:

  • GitHub prompts: Use @shortcuts with prompt: true
  • Claude agents: Use @agents block
  • Cursor rules: Map to @standards
  • Local content: Use @local block

Preserving Formatting

Use triple-quote multiline strings for:

  • Rich markdown content
  • Code examples
  • Complex instructions

Syntax Rules

Quick reference for PromptScript syntax:

  • Strings: quoted or identifier
  • Multi-line: triple quotes
  • Arrays: [item1, item2] or - item prefix
  • Objects: { key: value }
  • Comments: # comment
  • Required @meta fields: id, syntax

Quality Checklist

Before completing migration:

  • @meta block has id and syntax
  • Identity is clear and specific
  • Standards are organized by category
  • Restrictions use dash prefix (-)
  • Shortcut
Полный SKILL.md на GitHub

Установить migrate-to-promptscript в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Read
Write
Glob
Grep
Bash

Вложенные файлы

metadata.json

FAQ

Что делает скилл migrate-to-promptscript?

Migrate existing AI instruction files to PromptScript format

Как установить скилл migrate-to-promptscript?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл migrate-to-promptscript запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить migrate-to-promptscript с