Skip to content

Instantly share code, notes, and snippets.

@andynu
Created November 6, 2025 14:09
Show Gist options
  • Select an option

  • Save andynu/5d4e42f13822216ae539c2020af75b0d to your computer and use it in GitHub Desktop.

Select an option

Save andynu/5d4e42f13822216ae539c2020af75b0d to your computer and use it in GitHub Desktop.
Plan and execution plan for slash commands

Execute Plan Command

Overview

Execute a numerically-prefixed plan file from the plans folder based on the provided argument.

Instructions

Plan Selection

  • Read the plan file with prefix matching $ARGUMENTS from the plans folder
  • Check plans/index.md to see if the plan file has changed since last worked (compare Last Modified vs Last Worked timestamps)
  • If the plan has changed since last work, note this before proceeding
  • Ensure you understand the complete scope before beginning execution

Execution Guidelines

  1. Progress Tracking: Update the plan document with your progress as you work
  2. Commit Strategy:
    • Commit after each meaningful feature or fix is complete and working
    • Each commit should represent a single logical unit of work
    • Avoid bundling multiple unrelated changes in one commit
    • Never commit broken or failing code (unless intentionally adding failing tests before implementation)
    • Avoid mentioning Claude in commit messages
  3. Testing Approach:
    • Focus on light-touch unit and integration testing initially
    • Prioritize having passing tests over exhaustive coverage
    • Ensure basic functionality works before expanding test coverage

Work Flow

  • Read and understand the full plan first
  • Break work into logical, committable chunks
  • Update plan document with progress markers
  • Test each piece as you complete it
  • Commit working code with clear, descriptive messages
  • Update Index: When you begin or end work on the plan, update plans/index.md:
    • Set "Last Worked" to current timestamp when you start or finish a work session
    • Update "Status" field based on your progress ("In Progress", "Completed", "Blocked", etc.)
    • Update "Last Modified" from the actual plan file's modification time
    • Set "Changed Since Work" to "Yes" if Last Modified is newer than Last Worked, "No" otherwise
    • Update the index's "Last Updated" timestamp

Create Implementation Plan

Overview

Create a structured implementation plan document in the plans folder with auto-incremented numerical prefix.

Plan Creation Process

File Management

  1. Location: Save to plans/ folder
  2. Naming: Use auto-incremented prefix (001, 002, etc.) - find next available number
  3. Format: Standard markdown file (.md extension)
  4. Index Management: After creating the plan file, update plans/index.md:
    • Create the index file if it doesn't exist (use the template below)
    • Add a new row for this plan with:
      • Plan prefix number
      • Plan title (extracted from the first heading in the plan)
      • Status: "Not Started"
      • Last Worked: Current timestamp
      • Last Modified: Current timestamp (from file stats)
      • Changed Since Work: "No"

Plan Structure Requirements

Document Format

  • Start with high-level summary of the feature/change
  • Break down into implementable steps suitable for developer handoff
  • Use hierarchical technical numbering:
    1. Main Section
    1.1 Subsection
    1.2 Another Subsection
    1.2.1 Sub-subsection
    2. Next Main Section
    

Content Organization

  1. Executive Summary: Brief overview of what's being built/changed
  2. Technical Approach: High-level architectural decisions
  3. Implementation Steps: Detailed breakdown of work
  4. Testing Strategy: How to verify the implementation
  5. Acceptance Criteria: Definition of done

Input Processing

  1. Parse Requirements: Extract key functionality, constraints, and goals from the multi-paragraph input
  2. Identify Scope: Determine what needs to be built, modified, or integrated
  3. Structure Output: Transform the narrative requirements into the organized plan format above
  4. Add Technical Detail: Supplement user requirements with necessary technical considerations
  5. Create Actionable Steps: Break down abstract requirements into concrete implementation tasks

Index File Template

If plans/index.md doesn't exist, create it with this structure:

# Implementation Plans Index

Last Updated: [Current Timestamp]

| Plan | Title | Status | Last Worked | Last Modified | Changed Since Work |
|------|-------|--------|-------------|---------------|-------------------|

Status values: "Not Started", "In Progress", "Completed", "Blocked", "On Hold"

Raw Requirements

$ARGUMENTS

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment