بنقرة واحدة
create-target
Scaffold a new target type (e.g., Zed, Windsurf) for universal-ai-config
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Scaffold a new target type (e.g., Zed, Windsurf) for universal-ai-config
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
First example skill for add-skill tests
Second example skill with a non-kebab name
Validate uac's assumptions about supported AI tools (Claude Code, Copilot, Cursor, etc.) against current upstream documentation and produce a written report of drift — renamed fields, new events, deprecated features, schema changes — so the user can plan follow-up changes. Does not modify source code.
Import existing AI tool configurations (from Claude, Copilot, Cursor, or Codex) into universal-ai-config templates. Converts target-specific files into universal templates.
Draft a pull request description from either the current chat session or the full feature branch (committed + uncommitted). Use when the user asks to write a PR description, prep a PR, or summarize changes for review.
Create, update, or manage universal-ai-config agent templates. Handles finding existing agents, deciding whether to create or modify, and writing the template.
| name | create-target |
| description | Scaffold a new target type (e.g., Zed, Windsurf) for universal-ai-config |
| userInvocable | true |
| argumentHint | <target-name> |
Create a new target implementation for universal-ai-config. A target maps universal template frontmatter and hooks to a specific AI coding assistant's configuration format.
Research the target's config format — find up-to-date documentation online for how the target AI assistant expects its configuration files. Look for:
.cursor/rules/*.mdc, .github/instructions/*.md)tools: frontmatter, and any allow/deny lists. Find the exact string format (e.g. mcp__server__tool, server/tool, MCP:tool) and the wildcard convention for "all tools on a server"Look through docs for all supported configuration types:
Present findings for approval — before writing any code, present a structured summary of your research to the user. For each supported configuration type, include:
Format as a clear table or grouped list so the user can review each mapping. Ask the user to approve or flag any corrections before proceeding. Do not continue until the user explicitly approves.
After the user approves the research findings, enter plan mode to design the full implementation before writing any code. The plan should cover:
Review existing targets for patterns — read through at least one existing target implementation (e.g., src/targets/claude/index.ts) and the shared types to understand the exact interfaces and conventions you need to follow.
Draft the implementation plan — produce a detailed, step-by-step plan that includes:
Target definition: the full defineTarget() structure — name, outputDir, supportedTypes, and for each supported type:
frontmatterMap — every universal key and what it maps to (string rename or function transform), with reasoninggetOutputPath — the exact path logic, including how alwaysApply or other flags affect routingHooks (if supported): transform function logic mapping universal event names → target events, outputPath, and mergeKey if the hook config nests inside a larger file
Registration: changes needed in src/targets/index.ts and the Target type in src/types.ts
Config schema: any changes needed in src/config/schema.ts or src/config/defaults.ts
Tests: which fixture(s) to use or create, and what assertions to write
Docs: any updates needed to README, meta-instruction templates, or seed files
Upstream validation reference: draft the full content of a new 2.X <Tool Name> section for .universal-ai-config/skills/report-feature-changes/upstream-validation-reference.md (following the Part 4 template in that file) as part of the plan — include it inline so the user can review and correct the URLs and per-feature mappings before anything is written. The draft must cover:
— note for categories the target doesn't support.This is mandatory — without it the report-feature-changes skill has no reference URLs and the target will silently drift.
Reference the defineTarget() pattern:
import { defineTarget } from "../define-target.js";
import type { UniversalFrontmatter, UniversalHookHandler } from "../../types.js";
export default defineTarget({
name: "<target-name>",
outputDir: ".<target-dir>",
supportedTypes: ["instructions", "skills", "agents", "hooks"],
instructions: {
frontmatterMap: {
description: "description",
globs: "<target-specific-key>",
alwaysApply: "<target-specific-key>",
},
getOutputPath: (name, fm) => `rules/${name}.<ext>`,
},
// skills, agents — similar pattern
// hooks — implement transform function
});
Key decisions to address in the plan:
frontmatterMap: maps universal keys → target keys. Use a string for direct rename, or a function (value, fm) => Record<string, unknown> for transformsgetOutputPath: determines output file path from template name and frontmatterconsolidate: if the target maps multiple templates of a type into one or more output files (e.g., many instructions → one AGENTS.md), use the consolidate function on TemplateTypeConfig instead of getOutputPath. Consolidate-based types can also emit files at root-relative paths outside outputDir. See the Codex target for a reference implementation.transform: converts universal event names and handler format to target formatmergeKey: if the target's hook config is nested inside a larger settings file (like Claude's settings.json which has a hooks key)mcpToolRef update: add a case "<target>" branch to mcpToolRef() in src/core/parser.ts with both the specific-tool form (e.g. server/tool) and the wildcard form (e.g. server/*). Derive these from the MCP tool reference syntax you found in Phase 1.UniversalFrontmatter, UniversalMCPServer, or UniversalHookHandler for lossless round-trip fidelity. If so, plan additions to src/types.ts and the meta-instruction uac-template-guide.md field tables. Common triggers: target-specific auth options, timeout knobs, per-server tool allow/denylists, agent sandbox modes.format: "toml" on HooksTypeConfig/MCPTypeConfig, a mergeTomlKey writer primitive analogous to the existing mergeJsonKey.Get plan approval — present the plan to the user for review. Do not start implementing until the plan is approved.
Once the plan is approved, execute it:
Create the target directory — create src/targets/<name>/index.ts
Implement defineTarget() — follow the approved plan to build the full target definition
Register the target — add to src/targets/index.ts and the Target type in src/types.ts
Add mcpToolRef case — add the new case "<target>" branch to mcpToolRef() in src/core/parser.ts. Add corresponding test cases to tests/unit/parser.test.ts (specific-tool and wildcard forms for the new target).
Add new universal type fields — if the plan identified new fields for UniversalFrontmatter, UniversalMCPServer, or UniversalHookHandler, add them to src/types.ts now. Also update the uac-template-guide.md field tables to document the new fields with their per-target support annotations.
Add tests — create integration tests using existing fixtures that generate for the new target, verifying output paths and content
Update the upstream validation reference — copy the draft section from the approved plan into .universal-ai-config/skills/report-feature-changes/upstream-validation-reference.md, applying any corrections the user made during plan review. After inserting, skim Part 1 of that file and confirm every feature category your target supports has a corresponding row in the per-feature index.
Run pnpm check to verify everything passes