Files
Claude-Code-Workflow/.claude/scripts/tech-stack-loader.sh
catlog22 445ac823ba Initial release: Claude Code Workflow (CCW) v2.0
🚀 Revolutionary AI-powered development workflow orchestration system

## 🔥 Core Innovations
- **Document-State Separation**: Markdown for planning, JSON for execution state
- **Progressive Complexity Management**: Level 0-2 adaptive workflow depth
- **5-Agent Orchestration**: Specialized AI agents with context preservation
- **Session-First Architecture**: Auto-discovery and state inheritance

## 🏗️ Key Features
- Intelligent workflow orchestration (Simple/Medium/Complex patterns)
- Real-time document-state synchronization with conflict resolution
- Hierarchical task management with 3-level JSON structure
- Gemini CLI integration with 12+ specialized templates
- Comprehensive file output generation for all workflow commands

## 📦 Installation
Remote one-liner installation:
```
iex (iwr -useb https://raw.githubusercontent.com/catlog22/Claude-CCW/main/install-remote.ps1)
```

## 🎯 System Architecture
4-layer intelligent development architecture:
1. Command Layer - Smart routing and version management
2. Agent Layer - 5 specialized development agents
3. Workflow Layer - Gemini templates and task orchestration
4. Memory Layer - Distributed documentation and auto-sync

🤖 Generated with Claude Code

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-07 17:39:54 +08:00

101 lines
3.2 KiB
Bash

#!/bin/bash
# tech-stack-loader.sh - DMSFlow Tech Stack Guidelines Loader
# Returns tech stack specific coding guidelines and best practices for Claude processing
set -e
# Define paths
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
TEMPLATE_DIR="${SCRIPT_DIR}/../tech-stack-templates"
# Parse arguments
COMMAND="$1"
TECH_STACK="$2"
# Handle version check
if [ "$COMMAND" = "--version" ] || [ "$COMMAND" = "-v" ]; then
echo "DMSFlow tech-stack-loader v2.0"
echo "Semantic-based development guidelines system"
exit 0
fi
# List all available guidelines
if [ "$COMMAND" = "--list" ]; then
echo "Available Development Guidelines:"
echo "================================="
for file in "$TEMPLATE_DIR"/*.md; do
if [ -f "$file" ]; then
# Extract name and description from YAML frontmatter
name=$(grep "^name:" "$file" | head -1 | cut -d: -f2 | sed 's/^ *//' | sed 's/ *$//')
desc=$(grep "^description:" "$file" | head -1 | cut -d: -f2- | sed 's/^ *//' | sed 's/ *$//')
if [ -n "$name" ] && [ -n "$desc" ]; then
printf "%-20s - %s\n" "$name" "$desc"
fi
fi
done
exit 0
fi
# Load specific guidelines
if [ "$COMMAND" = "--load" ] && [ -n "$TECH_STACK" ]; then
TEMPLATE_PATH="${TEMPLATE_DIR}/${TECH_STACK}.md"
if [ -f "$TEMPLATE_PATH" ]; then
# Output content, skipping YAML frontmatter
awk '
BEGIN { in_yaml = 0; yaml_ended = 0 }
/^---$/ {
if (!yaml_ended) {
if (in_yaml) yaml_ended = 1
else in_yaml = 1
next
}
}
yaml_ended { print }
' "$TEMPLATE_PATH"
else
>&2 echo "Error: Development guidelines '$TECH_STACK' not found"
>&2 echo "Use --list to see available guidelines"
exit 1
fi
exit 0
fi
# Handle legacy usage (direct tech stack name)
if [ -n "$COMMAND" ] && [ "$COMMAND" != "--help" ] && [ "$COMMAND" != "--list" ] && [ "$COMMAND" != "--load" ]; then
TEMPLATE_PATH="${TEMPLATE_DIR}/${COMMAND}.md"
if [ -f "$TEMPLATE_PATH" ]; then
# Output content, skipping YAML frontmatter
awk '
BEGIN { in_yaml = 0; yaml_ended = 0 }
/^---$/ {
if (!yaml_ended) {
if (in_yaml) yaml_ended = 1
else in_yaml = 1
next
}
}
yaml_ended { print }
' "$TEMPLATE_PATH"
exit 0
else
>&2 echo "Error: Development guidelines '$COMMAND' not found"
>&2 echo "Use --list to see available guidelines"
exit 1
fi
fi
# Show help
echo "Usage:"
echo " tech-stack-loader.sh --list List all available guidelines with descriptions"
echo " tech-stack-loader.sh --load <name> Load specific development guidelines"
echo " tech-stack-loader.sh <name> Load specific guidelines (legacy format)"
echo " tech-stack-loader.sh --help Show this help message"
echo " tech-stack-loader.sh --version Show version information"
echo ""
echo "Examples:"
echo " tech-stack-loader.sh --list"
echo " tech-stack-loader.sh --load javascript-dev"
echo " tech-stack-loader.sh python-dev"