### Full README Example with Badges and Quick Start Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/documentation-guide/readme-template.md A comprehensive README template featuring badges, installation instructions for multiple package managers, a quick start guide, and sections for documentation, configuration, examples, contributing, changelog, FAQ, support, acknowledgments, and license. ```markdown # Project Name [![CI Status](https://github.com/org/repo/actions/workflows/ci.yml/badge.svg)](https://github.com/org/repo/actions) [![npm version](https://badge.fury.io/js/project-name.svg)](https://www.npmjs.com/package/project-name) [![Coverage](https://codecov.io/gh/org/repo/branch/main/graph/badge.svg)](https://codecov.io/gh/org/repo) Brief description of what this project does and why it exists. ## Features - **Fast**: 10x faster than alternatives - **Simple**: Easy to learn API - **Extensible**: Plugin architecture - **Type-safe**: Full TypeScript support ## Installation ### npm ```bash npm install project-name ``` ### yarn ```bash yarn add project-name ``` ### pnpm ```bash pnpm add project-name ``` ## Quick Start ```javascript const { Client } = require('project-name'); const client = new Client({ apiKey: 'your-key' }); const result = await client.doSomething(); console.log(result); ``` ## Documentation - [Getting Started](docs/getting-started.md) - [API Reference](docs/api-reference.md) - [Configuration](docs/configuration.md) - [Examples](examples/) ## Configuration | Option | Type | Default | Description | |--------|------|---------|-------------| | `apiKey` | string | - | Your API key | | `timeout` | number | 30000 | Request timeout in ms | | `retries` | number | 3 | Number of retry attempts | ## Examples See the [examples/](examples/) directory for complete examples: - [Basic Usage](examples/basic/) - [Advanced Features](examples/advanced/) - [Integration](examples/integration/) ## Contributing We welcome contributions! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines. ### Development Setup ```bash git clone https://github.com/org/repo.git cd repo npm install npm test ``` ## Changelog See [CHANGELOG.md](CHANGELOG.md) for version history. ## FAQ ### How do I do X? Answer to common question. ### Why does Y happen? Explanation of behavior. ## Support - [GitHub Issues](https://github.com/org/repo/issues) - [Documentation](https://docs.example.com) - [Discord](https://discord.gg/example) ## Acknowledgments - [Library A](https://example.com) - Used for X - [Person B](https://github.com/person) - Initial idea ## License MIT - see [LICENSE](LICENSE) for details. ``` -------------------------------- ### Setup Go Testify Framework Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/tdd-assistant/language-examples.md Installs the testify testing framework for Go projects using the go get command. ```bash go get github.com/stretchr/testify ``` -------------------------------- ### Outdated Installation Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/documentation-guide/readme-template.md An example of an outdated installation command, highlighting a common mistake in READMEs. ```bash npm install old-package-name ``` -------------------------------- ### Quickstart Command Implementation Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/specs/superspec-phase4-spec.md This JavaScript code defines the interactive workflow guide for the UDS quickstart command. It uses inquirer prompts to guide users through different development workflows and displays the recommended commands for each. ```javascript /** * Quickstart Command - Interactive workflow guide * * Reduces cognitive load of 22 CLI + 47 Skills by guiding users * to the most common workflow paths. * * Inspired by SuperSpec's 15-command simplicity. * * @module commands/quickstart */ import chalk from 'chalk'; import { select } from '@inquirer/prompts'; const WORKFLOWS = [ { name: 'Quick Spec โ†’ Implement (Micro-Spec)', description: 'Lightweight spec for simple features/fixes', steps: [ { cmd: 'uds spec create "your feature"', desc: 'Create micro-spec from intent' }, { cmd: 'uds spec confirm SPEC-XXX', desc: 'Confirm spec for implementation' }, { cmd: '# Implement in your editor', desc: 'Write code following the spec' }, { cmd: 'uds spec archive SPEC-XXX', desc: 'Archive completed spec' }, ], }, { name: 'Full SDD Spec Flow (Boost)', description: 'Complete spec-driven development for complex features', steps: [ { cmd: 'uds spec create "your feature" --boost', desc: 'Create full SDD spec with design sections' }, { cmd: 'uds lint', desc: 'Validate spec quality and cross-references' }, { cmd: 'uds spec confirm SPEC-XXX', desc: 'Confirm after review' }, { cmd: '# Implement with /derive โ†’ /tdd', desc: 'Use forward derivation and TDD' }, { cmd: 'uds sync', desc: 'Export context for session resume' }, ], }, { name: 'Test-Driven Development (TDD)', description: 'Red-Green-Refactor cycle', steps: [ { cmd: 'uds workflow execute tdd', desc: 'Start TDD workflow' }, { cmd: '# Write failing test (RED)', desc: 'Define expected behavior' }, { cmd: '# Make it pass (GREEN)', desc: 'Minimal implementation' }, { cmd: '# Improve (REFACTOR)', desc: 'Clean up without breaking tests' }, ], }, { name: 'Check Project Health', description: 'Audit standards compliance and spec quality', steps: [ { cmd: 'uds check', desc: 'Check standards file integrity' }, { cmd: 'uds check --spec-size', desc: 'Check spec sizes against limits' }, { cmd: 'uds lint', desc: 'Lint specs for AC coverage and dependency validity' }, { cmd: 'uds audit', desc: 'Deep health diagnosis' }, ], }, { name: 'Resume Previous Work', description: 'Restore context from a previous session', steps: [ { cmd: 'uds sync', desc: 'Generate context.md from git diff + workflow state' }, { cmd: 'cat .workflow-state/context.md', desc: 'Read context in new session' }, { cmd: 'uds workflow status', desc: 'Check workflow execution status' }, ], }, ]; /** * Execute the quickstart command */ export async function quickstartCommand() { console.log(chalk.bold('\n๐Ÿš€ UDS Quickstart Guide\n')); console.log(chalk.gray('Select a workflow to see the recommended commands:\n')); const choices = WORKFLOWS.map((w, i) => ({ name: `${w.name}`, value: i, description: w.description, })); const selected = await select({ message: 'Which workflow do you want to follow?', choices, }); const workflow = WORKFLOWS[selected]; console.log(chalk.bold(`\n${workflow.name}\n`)); console.log(chalk.gray(`${workflow.description}\n`)); for (let i = 0; i < workflow.steps.length; i++) { const step = workflow.steps[i]; console.log(` ${chalk.cyan(`${i + 1}.`)} ${chalk.yellow(step.cmd)}`); console.log(` ${chalk.gray(step.desc)}\n`); } console.log(chalk.gray('Tip: Run each command in order. Use "uds quickstart" anytime to see this guide again.\n')); } ``` -------------------------------- ### Release Workflow Examples Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/release.md These examples demonstrate how to start a release branch, update the changelog, and finish a release for a specific version. ```bash # Start release v1.2.0 /release start 1.2.0 ``` ```bash # Update changelog for v1.2.0 /release changelog 1.2.0 ``` ```bash # Finish release /release finish 1.2.0 ``` -------------------------------- ### Create and Setup a Git Worktree Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/git-worktree.md Example of creating a new worktree for a feature branch and installing its dependencies. ```bash git worktree add .worktrees/feature-auth -b feature/auth cd .worktrees/feature-auth pnpm install # or npm install, pip install, etc. ``` -------------------------------- ### Skills Installation Strategy A Example (1-2 Tools) Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/init.md When configuring 1-2 AI tools that support Skills, use this combined question format to ask about installation location. Options include Plugin Marketplace, User Level, Project Level, or skipping installation. ```bash Question: "Skills ่ฆๅฎ‰่ฃๅˆฐๅ“ช่ฃก๏ผŸ" Options: 1. Plugin Marketplace (ๅปบ่ญฐ) - ่‡ชๅ‹•ๆ›ดๆ–ฐ๏ผŒๆ˜“ๆ–ผ็ฎก็† 2. User Level (~/.claude/skills/) - ๆ‰€ๆœ‰ๅฐˆๆกˆๅ…ฑ็”จ 3. Project Level (.claude/skills/) - ๅƒ…ๆญคๅฐˆๆกˆ 4. ่ทณ้Ž - ไธๅฎ‰่ฃ Skills ``` ```bash Question: "Skills ่ฆๅฎ‰่ฃๅˆฐๅ“ช่ฃก๏ผŸ" Options: 1. Plugin Marketplace + OpenCode Project Level (ๅปบ่ญฐ) 2. ๅ…จ้ƒจ User Level - ๆ‰€ๆœ‰ๅฐˆๆกˆๅ…ฑ็”จ 3. ๅ…จ้ƒจ Project Level - ๅƒ…ๆญคๅฐˆๆกˆ 4. ่ทณ้Ž - ไธๅฎ‰่ฃ Skills ``` -------------------------------- ### Commands Installation Strategy A Example (1-2 Tools) Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/init.md When configuring 1-2 AI tools that support Commands, use this combined question format to ask about installation location. Options include User Level, Project Level, or skipping installation. ```bash Question: "Commands ่ฆๅฎ‰่ฃๅˆฐๅ“ช่ฃก๏ผŸ" Options: 1. User Level (~/.config/opencode/command/) - ๆ‰€ๆœ‰ๅฐˆๆกˆๅ…ฑ็”จ 2. Project Level (.opencode/command/) - ๅƒ…ๆญคๅฐˆๆกˆ (ๅปบ่ญฐ) 3. ่ทณ้Ž - ไฝฟ็”จ Skills ๅณๅฏ ``` ```bash Question: "Commands ่ฆๅฎ‰่ฃๅˆฐๅ“ช่ฃก๏ผŸ" Options: 1. ๅ…จ้ƒจ User Level - ๆ‰€ๆœ‰ๅฐˆๆกˆๅ…ฑ็”จ 2. ๅ…จ้ƒจ Project Level (ๅปบ่ญฐ) - ๅƒ…ๆญคๅฐˆๆกˆ 3. ่ทณ้Ž - ไฝฟ็”จ Skills ๅณๅฏ ``` -------------------------------- ### Skills Installation Strategy B Stage 1 Example (3+ Tools) Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/init.md For 3 or more AI tools supporting Skills, the first stage involves asking users if they prefer a unified installation level for all tools, individual levels, or to skip installation. ```bash Question: "ๆ‚จ้ธๆ“‡ไบ† 3 ๅ€‹ไปฅไธŠ็š„ AI ๅทฅๅ…ท๏ผŒSkills ๅฎ‰่ฃๅฑค็ดš่ฆๅฆ‚ไฝ•่จญๅฎš๏ผŸ" Options: 1. ็ตฑไธ€ๅฑค็ดš (ๅปบ่ญฐ) - ๆ‰€ๆœ‰ๅทฅๅ…ทไฝฟ็”จ็›ธๅŒๅฑค็ดš 2. ๅ€‹ๅˆฅ่จญๅฎš - ็‚บๆฏๅ€‹ๅทฅๅ…ทๅˆ†ๅˆฅ้ธๆ“‡ๅฑค็ดš 3. ่ทณ้Ž - ไธๅฎ‰่ฃ Skills ``` -------------------------------- ### Migration Guide Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/versioning.md Illustrates how to document breaking changes between API versions using markdown. Shows before and after code examples for function calls and response formats. ```markdown # Migration Guide: v1.x to v2.0 ## Breaking Changes ### 1. authenticate() removed **Before (v1.x)**: ```javascript const token = await authenticate('user', 'pass'); ``` **After (v2.0)**: ```javascript const token = await authenticateV2({ username: 'user', password: 'pass' }); ``` ### 2. API response format changed **Before (v1.x)**: ```json { "data": { "user": {...} } } ``` **After (v2.0)**: ```json { "user": {...} } ``` Update your code: ```javascript // Before const user = response.data.user; // After const user = response.user; ``` ``` -------------------------------- ### Start Interactive Migration Guide Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/migration-assistant/SKILL.md Initiates an interactive guide for code migration, framework upgrades, or technology modernization. ```bash User: /migrate ``` -------------------------------- ### Commands Installation Strategy B Stage 1 Example (3+ Tools) Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/init.md For 3 or more AI tools supporting Commands, the first stage involves asking users if they prefer a unified installation level for all tools, individual levels, or to skip installation. ```bash Question: "ๆ‚จ้ธๆ“‡ไบ†ๅคšๅ€‹ๆ”ฏๆด Commands ็š„ AI ๅทฅๅ…ท๏ผŒๅฎ‰่ฃๅฑค็ดš่ฆๅฆ‚ไฝ•่จญๅฎš๏ผŸ" Options: 1. ็ตฑไธ€ๅฑค็ดš (ๅปบ่ญฐ) - ๆ‰€ๆœ‰ๅทฅๅ…ทไฝฟ็”จ็›ธๅŒๅฑค็ดš 2. ๅ€‹ๅˆฅ่จญๅฎš - ็‚บๆฏๅ€‹ๅทฅๅ…ทๅˆ†ๅˆฅ้ธๆ“‡ๅฑค็ดš 3. ่ทณ้Ž - ไธๅฎ‰่ฃ Commands ``` -------------------------------- ### Skills Status Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/check.md Shows the installation status for configured AI tools, indicating whether skills and commands are installed and providing version information. ```text Skills Status Claude Code: โœ“ Skills installed: - User level: ~/.claude/skills/ Version: 3.5.1 โœ“ Commands: 7 installed Path: .opencode/commands/ ``` -------------------------------- ### Minimal README Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/documentation-guide/readme-template.md A basic README structure including Project Name, Description, Installation, Usage, and License. ```markdown # Project Name Brief description of what this project does. ## Installation ```bash npm install project-name ``` ## Usage ```javascript const lib = require('project-name'); lib.doSomething(); ``` ## License MIT ``` -------------------------------- ### Bash Command for Package Installation and Testing Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/documentation-structure.md This snippet demonstrates basic npm commands for installing a package and running tests. It is often used in CLI examples or scripts. ```bash npm install your-package npm test ``` -------------------------------- ### Skills Installation Strategy B Stage 2a Example (Unified Level) Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/init.md If a unified installation level is chosen for multiple Skills, this question prompts the user to select between User Level (shared across projects) or Project Level (specific to the current project). ```bash Question: "ๆ‰€ๆœ‰ Skills ่ฆๅฎ‰่ฃๅˆฐๅ“ชๅ€‹ๅฑค็ดš๏ผŸ" Options: 1. User Level - ๆ‰€ๆœ‰ๅฐˆๆกˆๅ…ฑ็”จ 2. Project Level (ๅปบ่ญฐ) - ๅƒ…ๆญคๅฐˆๆกˆ ``` -------------------------------- ### Daily Workflow Example: Assess and Develop Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/docs/USER-MANUAL.md This example demonstrates a typical day using UDS commands, starting with assessing a module, creating a specification, deriving tests, and following the TDD cycle. ```bash 09:00 /discover auth # Assess the auth module before changes โ†’ Health score 7.2/10, CONDITIONAL 09:15 /sdd add-2fa # Create two-factor auth specification โ†’ Output: SPEC-001.md 09:30 /sdd review # Review spec completeness โ†’ 4 ACs confirmed, no gaps 09:45 /derive-all # Generate BDD + TDD from spec โ†’ Output: 4 .feature files + 4 .test.ts files 10:00 /tdd red # Start TDD cycle 10:30 /tdd green # Implement minimum code 11:00 /tdd refactor # Improve quality โ†’ Repeat cycle until all ACs complete 12:00 /commit # Standardized commit โ†’ feat(auth): add two-factor authentication 12:05 /review # Final review โ†’ 0 BLOCKING, 1 SUGGESTION ``` -------------------------------- ### Run 'uds init' Interactively Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/docs/CLI-INIT-OPTIONS.md Initiates the 'uds init' command with full interactive prompts to guide the setup process. ```bash uds init ``` -------------------------------- ### Standard README Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/documentation-guide/readme-template.md A standard README template that includes Features, Installation, Usage, Documentation, Contributing, and License sections. ```markdown # Project Name Brief description of what this project does. ## Features - Feature 1 - Feature 2 - Feature 3 ## Installation ```bash npm install project-name ``` ## Usage ```javascript const { feature } = require('project-name'); // Basic usage feature.doSomething(); // With options feature.doSomething({ option: 'value' }); ``` ## Documentation See [docs/](docs/) for detailed documentation. ## Contributing Contributions welcome! See [CONTRIBUTING.md](CONTRIBUTING.md). ## License MIT - see [LICENSE](LICENSE) ``` -------------------------------- ### Commands Installation Strategy B Stage 2a Example (Unified Level) Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/init.md If a unified installation level is chosen for multiple Commands, this question prompts the user to select between User Level (shared across projects) or Project Level (specific to the current project). ```bash Question: "ๆ‰€ๆœ‰ Commands ่ฆๅฎ‰่ฃๅˆฐๅ“ชๅ€‹ๅฑค็ดš๏ผŸ" Options: 1. User Level - ๆ‰€ๆœ‰ๅฐˆๆกˆๅ…ฑ็”จ 2. Project Level (ๅปบ่ญฐ) - ๅƒ…ๆญคๅฐˆๆกˆ ``` -------------------------------- ### Development Workflow Steps Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/docs/WINDOWS-GUIDE.md A step-by-step guide for the development workflow, including cloning, installing dependencies, running tests and linting, linking for local testing, and testing CLI commands. ```powershell # 1. Clone repository git clone https://github.com/AsiaOstrich/universal-dev-standards.git cd universal-dev-standards # 2. Install CLI dependencies cd cli npm install # 3. Run tests npm test # 4. Run linting npm run lint # 5. Link for local testing npm link # 6. Test CLI commands uds list uds init --help ``` -------------------------------- ### index.md - Documentation Hub Structure Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/documentation-guide/documentation-structure.md An example structure for the main documentation index file, providing links to various sections like Getting Started, Guides, Reference, and Operations. ```markdown # Documentation Index ## Getting Started - [Quick Start](getting-started.md) - [Installation](installation.md) ## Guides - [User Guide](user-guide.md) - [Developer Guide](developer-guide.md) ## Reference - [API Reference](api-reference.md) - [Configuration](configuration.md) ## Operations - [Deployment](deployment.md) - [Troubleshooting](troubleshooting.md) ``` -------------------------------- ### Basic /guide Command Usage Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/guide.md Use the /guide command followed by a topic to access specific documentation. If no topic is provided, it lists all available guides. ```bash /guide [topic] ``` ```bash /guide git ``` ```bash /guide testing ``` ```bash /guide structure ``` ```bash /guide ``` -------------------------------- ### CLI Command Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/docs/specs/README.md Example of a CLI command for initializing a project. ```bash `init` ``` -------------------------------- ### Cursor-based Pagination Request Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/api-design-standards.md Example of an HTTP GET request using cursor-based pagination parameters. ```http GET /v1/events?limit=20&cursor=eyJpZCI6MTAwfQ== ``` -------------------------------- ### Offset-based Pagination Request Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/api-design-standards.md Example of an HTTP GET request using offset-based pagination parameters. ```http GET /v1/users?page=2&limit=20 ``` -------------------------------- ### RSpec Gemfile Setup (Ruby) Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/tdd-assistant/language-examples.md Add these gems to your Gemfile for RSpec testing. Run 'bundle install' to install them. ```ruby # Gemfile group :test do gem 'rspec', '~> 3.12' gem 'rspec-mocks' end ``` -------------------------------- ### First-Time Setup Configuration Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/checkin-assistant/guide.md When no specific check-in configuration is found, document the standard build, test, and quality commands, along with minimum coverage requirements, in the `CONTRIBUTING.md` file. ```markdown ## Check-in Standards ### Build Commands ```bash npm run build ``` ### Test Commands ```bash npm test ``` ### Quality Commands ```bash npm run lint ``` ### Minimum Coverage - Line: 80% - Branch: 75% ``` -------------------------------- ### Get Observability Guide for Specific Service Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/observability-assistant/SKILL.md Obtain a tailored observability guide for a particular service by providing its name. ```bash /observability "payment-service" ``` -------------------------------- ### Full UDS Configuration Example (YAML) Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/docs-generator/guide.md Example of a .usage-docs.yaml file configuring multi-language output, paths, and sources for CLI and skills. ```yaml # .usage-docs.yaml - Full UDS configuration version: "1.0" output: directory: "docs/" formats: [reference, cheatsheet] languages: [en, zh-TW, zh-CN] paths: en: "docs/" zh-TW: "locales/zh-TW/docs/" zh-CN: "locales/zh-CN/docs/" sources: cli: enabled: true entry: "cli/bin/uds.js" skills: enabled: true directory: "skills/" pattern: "**/SKILL.md" ``` -------------------------------- ### Pytest Setup and Configuration (Bash/INI) Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/tdd-assistant/language-examples.md Installs necessary pytest packages and configures pytest settings. Ensure pytest is installed. ```bash pip install pytest pytest-cov pytest-mock ``` ```ini # pytest.ini [pytest] testpaths = tests python_files = test_*.py python_functions = test_* addopts = -v --tb=short ``` -------------------------------- ### Example: Create User (Bash) Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/documentation-writing-standards.md A complete, runnable example demonstrating how to create a user via a POST request using curl. Includes prerequisites, request, and expected response. ```bash curl -X POST https://api.example.com/v1/users \ -H "Authorization: Bearer $API_KEY" \ -H "Content-Type: application/json" \ -d '{"name": "John", "email": "john@example.com"}' ``` -------------------------------- ### Setup GitHub Copilot Instructions Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/README.md Creates a .github directory and copies the Copilot instructions file into it. This is used to configure GitHub Copilot's behavior. ```bash mkdir -p .github cp skills/tools/copilot/copilot-instructions.md .github/copilot-instructions.md ``` -------------------------------- ### Cucumber.js Hooks for Setup and Teardown Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/bdd-assistant/gherkin-guide.md TypeScript example of using Cucumber.js hooks (BeforeAll, Before, After, AfterAll) for managing test setup and teardown. ```typescript // In step definitions import { Before, After, BeforeAll, AfterAll } from '@cucumber/cucumber'; BeforeAll(async function () { // Setup once before all scenarios await database.connect(); }); Before(async function () { // Setup before each scenario await database.beginTransaction(); }); After(async function () { // Cleanup after each scenario await database.rollback(); }); AfterAll(async function () { // Cleanup once after all scenarios await database.disconnect(); }); ``` -------------------------------- ### Typical SDD Workflow Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/derive-all.md This snippet illustrates a common workflow involving SDD creation, review, and subsequent test derivation using /derive-all. ```bash /sdd user-authentication # Step 1: Create spec /sdd review specs/SPEC-001.md # Step 2: Review /derive-all specs/SPEC-001.md # Step 3: Derive tests # Step 4: Implement โ€” fill [TODO] markers ``` -------------------------------- ### Refactor Decide Command Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/refactoring-assistant/SKILL.md Example of initiating the refactor vs. rewrite decision tree. The AI asks a series of questions to guide the decision. ```bash User: /refactor decide AI: Let me help you decide whether to refactor or rewrite. Question 1: Is the code currently working in production? [Y/N] ``` -------------------------------- ### OpenAPI Verification Schema Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/contract-test-assistant/guide.md An example OpenAPI schema defining the structure for a GET request to a user endpoint. This is used in provider-driven contract testing. ```yaml # openapi.yaml paths: /users/{id}: get: responses: '200': content: application/json: schema: $ref: '#/components/schemas/User' ``` -------------------------------- ### Show Observability Guide Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/observability-assistant/SKILL.md Use this command to display the main observability guide. ```bash /observability ``` -------------------------------- ### Good Commit Message Examples Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/checkin-standards.md Examples of well-formatted commit messages following conventional commit standards. Use these as a guide for clear and descriptive commit messages. ```git โœ… GOOD: "feat(auth): add OAuth2 Google login support" - OAuth flow implemented - Tests for happy path and errors - README updated with setup instructions - All existing tests pass ``` ```git โœ… GOOD: "fix(api): resolve memory leak in user session cache" - Memory leak identified and fixed - Regression test added - Load test shows leak resolved ``` ```git โœ… GOOD: "refactor(service): extract email validation to helper" - Email validation logic extracted - All call sites updated - Tests confirm identical behavior ``` -------------------------------- ### ATDD Command Usage Examples Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commands/atdd.md Examples of how to invoke the ATDD assistant via slash commands, including starting an interactive session or specifying a user story. ```bash /atdd ``` ```bash /atdd "user can reset password" ``` ```bash /atdd US-123 ``` -------------------------------- ### Usage Examples for Deploy Assistant Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/deploy-assistant/SKILL.md Examples demonstrating how to invoke the deploy assistant script interactively or with specific project types and options. ```bash /deploy # Interactive mode โ€” auto-detect project type /deploy node # Node.js project, generate directly /deploy docker # Docker Compose deploy mode /deploy --verify-only # Generate verify.sh only ``` -------------------------------- ### Install UDS CLI and Initialize Project Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/integrations/opencode/README.md Install the Universal Dev Standards CLI globally and use the 'uds init' command to set up your project, selecting OpenCode as the AI tool. This method also handles skills installation. ```bash # Install UDS CLI globally npm install -g universal-dev-standards # Initialize project - select OpenCode as your AI tool uds init ``` -------------------------------- ### Examples of Good and Bad Test Names Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/methodologies/guides/tdd-guide.md Provides examples of well-structured and poorly structured test names to guide developers in creating more readable and maintainable test suites. ```text โœ… Good test names: - should_return_empty_list_when_no_users_found - should_throw_validation_error_when_email_is_invalid - should_calculate_discount_when_order_exceeds_threshold โŒ Bad test names: - test1 - testCalculate - itWorks ``` -------------------------------- ### Usage Examples for Methodology Commands Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/dev-methodology/SKILL.md Demonstrates common commands for managing development methodologies, including switching, changing phases, and listing available options. ```bash # Show current status /methodology # Switch to Spec-Driven Development /methodology switch sdd # Move to GREEN phase (TDD) /methodology phase green # Show current phase checklist /methodology checklist # List all available methodologies /methodology list # Skip current phase (with warning) /methodology skip # Start custom methodology wizard /methodology create ``` -------------------------------- ### Example: Feature Implementation Next Steps Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/ai-response-navigation.md Use this format to suggest actions after a feature implementation is complete. Includes commands for testing, committing, and reviewing. ```markdown > **Suggested next steps:** > - Run `/test` to write tests for the new feature > - Run `/commit` to commit changes โญ **Recommended** โ€” changes are complete and verified > - Run `/review` for self-review ``` -------------------------------- ### Commit Message: Breaking Change Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/commit-message-guide.md Illustrates a breaking change in an API response format, detailing the changes and providing a migration guide with before/after JSON examples. ```text feat(api): Change user endpoint response format - Flatten nested user object structure - Remove deprecated `legacy_id` field - Add `created_at` and `updated_at` timestamps BREAKING CHANGE: User API response format changed Old format: ```json { "data": { "user": { "id": 123, "name": "John", "legacy_id": 456 } } } ``` New format: ```json { "id": 123, "name": "John", "created_at": "2025-11-12T10:00:00Z", "updated_at": "2025-11-12T10:00:00Z" } ``` Migration guide: - Update API clients to remove `.data` wrapper - Remove references to `legacy_id` field - Use `created_at` instead of `createdAt` (snake_case) Closes #234 ``` -------------------------------- ### Specify All 'uds init' Options Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/docs/CLI-INIT-OPTIONS.md Provides a comprehensive example of setting various 'uds init' options non-interactively, including format, skills location, workflow, merge strategy, output language, test levels, and content mode. ```bash uds init -y \ --format ai \ --skills-location marketplace \ --workflow github-flow \ --merge-strategy squash \ --output-lang english \ --test-levels unit,integration \ --content-mode index ``` -------------------------------- ### Complete Example Manifest Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/docs/specs/cli/shared/manifest-schema.md A comprehensive manifest file including all possible fields and configurations. ```json { "version": "3.3.0", "upstream": { "repo": "AsiaOstrich/universal-dev-standards", "version": "4.1.0", "installed": "2026-01-23T10:00:00.000Z" }, "level": 2, "format": "ai", "standardsScope": "full", "contentMode": "index", "standards": [ "core/anti-hallucination.md", "core/checkin-standards.md", "core/commit-message-guide.md", "core/code-review-checklist.md" ], "extensions": [ "extensions/languages/typescript-style.md" ], "integrations": [ "CLAUDE.md", ".cursorrules" ], "options": { "workflow": "github-flow", "merge_strategy": "squash", "output_language": "english", "test_levels": ["unit-testing", "integration-testing"] }, "aiTools": ["claude-code", "cursor"], "skills": { "installed": true, "location": "project", "names": ["commit-standards", "testing-guide"], "version": "4.1.0", "installations": [ { "agent": "claude-code", "level": "project" } ] }, "commands": { "installed": true, "names": ["uds-init", "uds-check"], "version": "4.1.0", "installations": [ { "agent": "claude-code", "level": "project" } ] }, "fileHashes": { ".standards/core/anti-hallucination.md": { "hash": "sha256:abc123...", "size": 5234, "installedAt": "2026-01-23T10:00:00.000Z" } }, "skillHashes": { "claude-code/project/commit-standards/SKILL.md": { "hash": "sha256:def456...", "size": 3456 } }, "commandHashes": { "claude-code/uds-check.md": { "hash": "sha256:ghi789...", "size": 2123 } }, "integrationBlockHashes": { "CLAUDE.md": { "hash": "sha256:jkl012...", "size": 4567 } }, "declined": { "agents": ["code-reviewer"], "workflows": ["pr-workflow"] } } ``` -------------------------------- ### Build Metadata Examples Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/versioning.md Demonstrates various ways to include build metadata in version strings, such as dates or commit hashes. ```text 1.0.0+20250112 # Date-based build 2.3.1+001 # Sequential build number 3.0.0+sha.5114f85 # Git commit hash 1.2.0-beta.1+exp.sha.5114f85 # Combined pre-release and build ``` -------------------------------- ### Example Directory Structure for Full Examples Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/ai-friendly-architecture.md Organize full code examples in a dedicated `examples/` directory within each module to provide complete implementations for various use cases. ```plaintext auth/ โ”œโ”€โ”€ QUICK-REF.md # Level 1 โ”œโ”€โ”€ README.md # Level 2 โ””โ”€โ”€ examples/ # Level 3 โ”œโ”€โ”€ basic-login.ts โ”œโ”€โ”€ oauth-integration.ts โ””โ”€โ”€ custom-middleware.ts ``` -------------------------------- ### Week 1: Zero-Cost Start Commands Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/docs/USER-MANUAL.md Begin with these two commands to immediately improve code quality by standardizing commit messages and performing self-reviews before pushing. ```bash /commit # Standardize commit messages /review # Self-review before push ``` -------------------------------- ### TypeScript/Cucumber.js Step Definition Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/bdd-assistant/bdd-workflow.md Provides a concrete example of step definitions using TypeScript with the Cucumber.js framework. Includes setup for test users and page objects, demonstrating asynchronous operations. ```typescript // TypeScript/Cucumber.js example import { Given, When, Then } from '@cucumber/cucumber'; import { expect } from 'chai'; Given('I am a registered user', async function () { this.user = await createTestUser(); }); When('I login with valid credentials', async function () { await this.loginPage.login(this.user.email, this.user.password); }); Then('I should see my dashboard', async function () { expect(await this.dashboardPage.isVisible()).to.be.true; }); ``` -------------------------------- ### Workflow Installation Flow Diagram Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/docs/specs/cli/workflow/01-workflow-installation.md Illustrates the step-by-step process for installing a workflow. ```text โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ Workflow Installation Flow โ”‚ โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค โ”‚ โ”‚ โ”‚ 1. Validate workflow name โ”‚ โ”‚ โ””โ”€โ”€ Check workflows/ directory for workflow definition โ”‚ โ”‚ โ”‚ โ”‚ 2. Check tool support โ”‚ โ”‚ โ””โ”€โ”€ Tool must support workflows (supportsWorkflows = true) โ”‚ โ”‚ โ”‚ โ”‚ 3. Determine target directory โ”‚ โ”‚ โ””โ”€โ”€ getWorkflowsDirForAgent(tool, location, projectPath) โ”‚ โ”‚ โ”‚ โ”‚ 4. Copy workflow files โ”‚ โ”‚ โ”œโ”€โ”€ WORKFLOW.md โ”‚ โ”‚ โ”œโ”€โ”€ steps/*.md โ”‚ โ”‚ โ”œโ”€โ”€ templates/*.md โ”‚ โ”‚ โ””โ”€โ”€ Compute file hashes โ”‚ โ”‚ โ”‚ โ”‚ 5. Update manifest โ”‚ โ”‚ โ””โ”€โ”€ Add to workflows.installed, update workflowHashes โ”‚ โ”‚ โ”‚ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ ``` -------------------------------- ### Authentication Module README Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/ai-friendly-architecture.md A sample structure for a detailed `README.md` file that provides comprehensive documentation for a module, including overview, architecture, API reference, configuration, and usage examples. ```markdown # Authentication Module ## Overview [2-3 paragraph description] ## Architecture [Diagram or description of internal structure] ## API Reference [Full function signatures with parameters] ## Configuration Options [All configuration with defaults and descriptions] ## Usage Examples [Common use cases with code samples] ## Error Handling [Error types and handling strategies] ``` -------------------------------- ### Application Entry Point - API Server Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/options/project-structure/go.md Example of a main function for an API server, loading configuration and starting the server. ```go package main import ( "log" "myproject/internal/config" "myproject/internal/server" ) func main() { cfg, err := config.Load() if err != nil { log.Fatal(err) } srv := server.New(cfg) if err := srv.Run(); err != nil { log.Fatal(err) } } ``` -------------------------------- ### Show SLO Guide and Create SLO Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/slo-assistant/SKILL.md Use these commands to display the SLO guide or create an SLO for a specific service. ```bash /slo # Show SLO guide /slo create "payment-service" # Create SLO for service ``` -------------------------------- ### Pre-release Version Examples Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/versioning.md Illustrates the format and ordering of pre-release versions, used for testing before a stable release. ```text 1.0.0-alpha.1 # First alpha release 1.0.0-alpha.2 # Second alpha release 1.0.0-beta.1 # First beta release 1.0.0-beta.2 # Second beta release 1.0.0-rc.1 # Release candidate 1 1.0.0 # Stable release ``` -------------------------------- ### GitHub Actions CI Pipeline Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/tdd-assistant/tdd-workflow.md An example GitHub Actions workflow for a TDD pipeline. It includes steps for checking out code, setting up Node.js, installing dependencies, running unit tests with coverage, integration tests, and end-to-end tests. ```yaml # GitHub Actions name: TDD Pipeline on: push: branches: [main, develop] pull_request: branches: [main] jobs: unit-tests: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 - run: npm ci - run: npm run test:unit -- --coverage - uses: codecov/codecov-action@v4 integration-tests: needs: unit-tests runs-on: ubuntu-latest services: postgres: image: postgres:15 env: POSTGRES_PASSWORD: test steps: - uses: actions/checkout@v4 - run: npm run test:integration e2e-tests: needs: integration-tests runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - run: npm run test:e2e ``` -------------------------------- ### Aider Integration File Structure Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/docs/specs/architecture/SPEC-NEW-INTEGRATIONS-BATCH-01.md Defines the expected file structure for the Aider integration, including agent rules and setup guide. ```bash integrations/ โ”œโ”€โ”€ aider/ โ”‚ โ”œโ”€โ”€ AGENTS.md # AI agent rules โ”‚ โ””โ”€โ”€ README.md # Setup guide โ”œโ”€โ”€ continue-dev/ โ”‚ โ”œโ”€โ”€ AGENTS.md # AI agent rules โ”‚ โ””โ”€โ”€ README.md # Setup guide โ””โ”€โ”€ REGISTRY.json # Updated with both entries ``` -------------------------------- ### List, Install, and Install All Workflows with UDS CLI Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/workflows/README.md Use the UDS CLI to manage available workflows. 'list' shows all available workflows, 'install ' installs a specific one, and 'install --all' installs all of them. ```bash # List available workflows uds workflow list ``` ```bash # Install specific workflow uds workflow install integrated-flow ``` ```bash # Install all workflows uds workflow install --all ``` -------------------------------- ### README.md Template Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/documentation-guide/documentation-structure.md A template for the main README.md file, including sections for features, installation, quick start, documentation, contributing, and license. ```markdown # Project Name Brief one-liner description. ## Features - Feature 1 - Feature 2 - Feature 3 ## Installation ```bash npm install project-name ``` ## Quick Start ```javascript const lib = require('project-name'); lib.doSomething(); ``` ## Documentation See [docs/](docs/) for full documentation. ## Contributing See [CONTRIBUTING.md](CONTRIBUTING.md). ## License [License Name](LICENSE) ``` -------------------------------- ### Recommended Testing Practices Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/CLAUDE.md Examples of recommended commands for efficient testing, including quick development testing, testing specific modules, and using test discovery. ```bash # โœ… Recommended: Quick development testing cd cli && npm run test:quick # โœ… Good: Test specific modules npm test -- tests/commands/ai-context.test.js tests/unit/utils/workflows-installer.test.js # โœ… Good: Use test discovery for targeted testing cd cli && npm run test:discover # โœ… Full test suite is now fast enough to run directly cd cli && npm test # ~6 minutes ``` -------------------------------- ### Conventional Commit Footer for Breaking Changes Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/skills/commit-standards/conventional-commits.md Example of how to denote breaking changes in the footer of a commit message, including a description and migration guide. ```markdown BREAKING CHANGE: Migration guide: - Step 1 - Step 2 ``` -------------------------------- ### In Progress Navigation Footer Example Source: https://github.com/asiaostrich/universal-dev-standards/blob/main/core/ai-response-navigation.md Apply this template when an intermediate stage of a multi-step task is completed. It guides the user to continue or adjust the process. ```markdown > **Progress: [N/M]. Next:** > - Continue to next stage โญ **Recommended** > - Adjust direction or parameters ```