Initial commit: Clean DSS implementation

Migrated from design-system-swarm with fresh git history.
Old project history preserved in /home/overbits/apps/design-system-swarm

Core components:
- MCP Server (Python FastAPI with mcp 1.23.1)
- Claude Plugin (agents, commands, skills, strategies, hooks, core)
- DSS Backend (dss-mvp1 - token translation, Figma sync)
- Admin UI (Node.js/React)
- Server (Node.js/Express)
- Storybook integration (dss-mvp1/.storybook)

Self-contained configuration:
- All paths relative or use DSS_BASE_PATH=/home/overbits/dss
- PYTHONPATH configured for dss-mvp1 and dss-claude-plugin
- .env file with all configuration
- Claude plugin uses ${CLAUDE_PLUGIN_ROOT} for portability

Migration completed: $(date)
🤖 Clean migration with full functionality preserved
This commit is contained in:
Digital Production Factory
2025-12-09 18:45:48 -03:00
commit 276ed71f31
884 changed files with 373737 additions and 0 deletions

64
.githooks/README.md Normal file
View File

@@ -0,0 +1,64 @@
# Git Hooks Configuration
This directory contains git hooks that protect the project's critical configuration and enforce code quality standards.
## Setup
To enable these hooks in your local git configuration, run:
```bash
git config core.hooksPath .githooks
```
Or set it globally:
```bash
git config --global core.hooksPath .githooks
```
## Protected Files
The `pre-commit` hook enforces immutability on these critical files:
- `.knowledge/dss-principles.json` - Core DSS principles
- `.knowledge/dss-architecture.json` - Architecture documentation
- `.clauderc` - Claude Code configuration
- `PROJECT_CONFIG.md` - Production deployment configuration
### Modifying Protected Files
If you need to modify a protected file, you must explicitly allow the change:
```bash
ALLOW_CORE_CHANGES=true git commit -m "your message"
```
## Quality Checks
The pre-commit hook also runs DSS code quality verification via `scripts/verify-quality.sh`, checking for:
- Inline event handlers (must use event delegation)
- Excessive inline styles (extract to Shadow DOM)
- Accessibility compliance
- Console statement limits
- Potential hardcoded secrets
- File size limits
To bypass quality checks (not recommended):
```bash
git commit --no-verify
```
## Hook Details
### pre-commit
- **Purpose:** Guard immutable files and enforce code quality
- **Trigger:** Before every commit
- **Exit Code:** 1 if checks fail (blocks commit), 0 if pass
- **Output:** Detailed report of any violations
---
**Last Updated:** 2025-12-08

64
.githooks/pre-commit Executable file
View File

@@ -0,0 +1,64 @@
#!/bin/bash
# DSS Immutability Guard - Simplified Version
# Protects core principle files from accidental modification
echo "🛡️ DSS Immutability Check..."
# List of protected files (core principles only)
PROTECTED_FILES=(
".knowledge/dss-principles.json"
".knowledge/dss-architecture.json"
".clauderc"
"PROJECT_CONFIG.md"
)
# Check if any protected files are being modified
MODIFIED_PROTECTED=()
for file in "${PROTECTED_FILES[@]}"; do
if git diff --cached --name-only | grep -q "^${file}$"; then
MODIFIED_PROTECTED+=("$file")
fi
done
# If protected files are modified, require confirmation
if [ ${#MODIFIED_PROTECTED[@]} -gt 0 ]; then
echo ""
echo "⚠️ WARNING: You are modifying protected core files:"
for file in "${MODIFIED_PROTECTED[@]}"; do
echo " - $file"
done
echo ""
echo "These files define DSS core architecture and should rarely change."
echo ""
echo "To proceed with this commit, set: ALLOW_CORE_CHANGES=true"
echo "Example: ALLOW_CORE_CHANGES=true git commit -m 'your message'"
echo ""
# Check if user has explicitly allowed the change
if [ "$ALLOW_CORE_CHANGES" != "true" ]; then
echo "❌ Commit blocked. Set ALLOW_CORE_CHANGES=true to proceed."
exit 1
fi
echo "✅ ALLOW_CORE_CHANGES=true detected. Proceeding with commit."
fi
echo "✅ Immutability check passed."
echo ""
# Run DSS code quality verification
echo "🔍 Running DSS Code Quality Checks..."
if [ -f "./scripts/verify-quality.sh" ]; then
if ! ./scripts/verify-quality.sh; then
echo ""
echo "❌ Code quality checks failed. Please fix the errors above."
echo "To bypass (not recommended): git commit --no-verify"
exit 1
fi
else
echo "⚠️ Warning: scripts/verify-quality.sh not found, skipping quality checks"
fi
echo ""
echo "✅ All pre-commit checks passed!"
exit 0