AI Integration

AI Tool Integration

CLDPM automatically generates configuration files for popular AI coding assistants when you run cldpm init. These files help AI tools understand CLDPM commands and mono repo structure.

Supported AI Tools

AI ToolConfig FileDescription
Claude CodeCLAUDE.mdProject instructions and CLDPM commands
Cursor IDE.cursor/rules/cldpm.mdcRules with glob patterns
Cline.clinerulesCLI commands and structure
Windsurf.windsurfrulesCommands and directory layout
GitHub Copilot.github/copilot-instructions.mdCLI reference

Generated Files

FileAI ToolLocation
CLAUDE.mdClaude CodeRoot directory
cldpm.mdcCursor IDE.cursor/rules/
.clinerulesClineRoot directory
.windsurfrulesWindsurfRoot directory
copilot-instructions.mdGitHub Copilot.github/

What's Included

Each configuration file contains:

  • CLDPM CLI commands - All available commands with examples
  • Directory structure - Mono repo layout explanation
  • Project workflows - Common tasks and how to accomplish them
  • Configuration files - Reference to cldpm.json and project.json

Example: Cursor Rules

---
description: CLDPM mono repo management commands
globs:
  - "**/*"
---
 
<!-- CLDPM-SECTION-START -->
# CLDPM - Claude Project Manager
 
You are working in a CLDPM mono repo...
 
## Available Commands
- `cldpm init [directory]` - Initialize a new mono repo
- `cldpm create project <name>` - Create a new project
...
<!-- CLDPM-SECTION-END -->

Section Markers

All generated content is wrapped with markers:

<!-- CLDPM-SECTION-START -->
... CLDPM content ...
<!-- CLDPM-SECTION-END -->

This enables:

Easy Updates

Run cldpm init --existing to update CLDPM sections without affecting other content

No Duplication

Existing CLDPM sections are replaced, not duplicated

Safe Appending

If no markers exist, content is appended to the file

Updating AI Configurations

New Repository

cldpm init my-repo

Creates all AI configuration files automatically.

Existing Repository

cd existing-repo
cldpm init --existing
  • Updates existing CLDPM sections if markers are present
  • Appends sections to files without CLDPM content
  • Skips files that already have unmarked CLDPM content

Manual Update

To force regenerate AI configurations:

# Remove existing markers and content, then reinitialize
cldpm init --existing

Customization

You can add your own content to these files. The CLDPM section markers ensure that only the CLDPM-specific content is updated when you run cldpm init --existing.

# My Custom Rules
 
These rules are specific to my project...
 
<!-- CLDPM-SECTION-START -->
# CLDPM - Claude Project Manager
... (auto-generated, will be updated)
<!-- CLDPM-SECTION-END -->
 
# More Custom Rules
 
Additional project-specific instructions...

Benefits

Consistent AI Behavior - All AI tools understand the same CLDPM commands and structure

Quick Onboarding - New team members' AI assistants immediately understand the project

Reduced Errors - AI tools suggest correct CLDPM commands instead of generic alternatives

Automatic Updates - Section markers allow safe updates as CLDPM evolves