@wundr.io/environment
v1.0.6
Published
Cross-platform development environment setup and management tools
Downloads
16
Maintainers
Readme
@wundr/environment
Cross-platform development environment setup and management tools for modern software development workflows.
🚀 Features
- Multi-Platform Support: macOS, Linux, Windows, and Docker
- Profile-Based Setup: Human developer, AI agent, and CI/CD runner profiles
- Tool Management: Automated installation and configuration of development tools
- AI Agent Integration: Claude Code, Claude Flow, and MCP tools support
- Package Manager Support: npm, pnpm, and yarn integration
- Environment Validation: Comprehensive health checks and validation
- Docker Support: Containerized development environments
- CLI Interface: Powerful command-line interface for environment management
📦 Installation
As a Package
# Install globally
npm install -g @wundr/environment
# Or use with npx
npx @wundr/environment initFrom Source
# Clone the repository
git clone https://github.com/wundr/wundr.git
cd wundr/packages/@wundr/environment
# Install dependencies
pnpm install
# Build the package
pnpm run build
# Link globally for development
pnpm link --global🎯 Quick Start
Initialize a New Environment
# Human developer environment (default)
wundr-env init --profile human --email [email protected] --name "Your Name"
# AI agent environment
wundr-env init --profile ai-agent --email [email protected] --name "AI Agent"
# CI/CD runner environment
wundr-env init --profile ci-runner --yesInstall Environment Tools
# Install all configured tools
wundr-env install
# Force reinstall existing tools
wundr-env install --forceValidate Environment
# Quick validation
wundr-env validate
# Detailed validation with verbose output
wundr-env validate --verboseCheck Environment Status
# Show current environment status
wundr-env status
# List available profiles
wundr-env profiles📋 Environment Profiles
Human Developer Profile
Complete development environment for human developers:
- Tools: Node.js, Git, Docker, VS Code, Claude Code, GitHub CLI
- Features: Full IDE setup, extensions, AI assistance
- Use Case: Daily development work, coding, debugging
AI Agent Profile
Optimized environment for AI agents and automation:
- Tools: Node.js, Git, Claude Code, Claude Flow, MCP tools
- Features: Swarm intelligence, neural patterns, automation
- Use Case: Autonomous code generation, AI-driven development
CI/CD Runner Profile
Minimal environment for continuous integration:
- Tools: Node.js, Git, essential build tools
- Features: Fast builds, testing framework, minimal footprint
- Use Case: Automated builds, testing, deployment pipelines
🛠️ Platform Support
macOS
# Automatic installation with Homebrew
./scripts/install/macos.shFeatures:
- Homebrew package management
- Xcode Command Line Tools integration
- Native app installations (VS Code, Docker Desktop)
Linux
# Supports Ubuntu, Debian, Fedora, CentOS, Arch
./scripts/install/linux.shFeatures:
- Multiple distribution support
- Package manager detection (apt, dnf, yum, pacman)
- Homebrew for Linux support
Windows
# PowerShell script with Chocolatey and Winget
.\scripts\install\windows.ps1Features:
- Chocolatey and Windows Package Manager
- WSL2 integration
- PowerShell profile configuration
Docker
# Build and run containerized environments
docker-compose up human-dev # Human developer environment
docker-compose up ai-agent # AI agent environment
docker-compose up ci-runner # CI/CD runner environment🧠 AI Agent Integration
Claude Code Integration
# Configure Claude Code with optimal settings
wundr-env update --profile ai-agentFeatures:
- Automatic model selection (Claude Opus 4.1)
- Code generation optimization
- Integration with development workflow
Claude Flow Orchestration
# Initialize swarm capabilities
claude-flow swarm init --agents 54Features:
- 54-agent swarm topology
- Neural pattern recognition
- Distributed memory system
- Consensus protocols
MCP Tools Support
# Available MCP tools
- claude-flow: Orchestration and swarm management
- wundr-toolkit: Quality and governance tools
- filesystem: File operations
- git: Version control operations
- docker: Container management🔧 Configuration
Environment Configuration
The environment configuration is stored in ~/.wundr/environment.json:
{
"profile": "human",
"platform": "macos",
"tools": [...],
"preferences": {
"editor": "vscode",
"shell": "zsh",
"packageManager": "pnpm",
"theme": "dark"
},
"paths": {
"development": "/Users/username/Development",
"config": "/Users/username/.wundr",
"cache": "/Users/username/.wundr/cache"
}
}Profile Templates
Profiles are defined in templates/profiles/:
human-developer.json: Full development environmentai-agent.json: AI agent optimized setupci-runner.json: Minimal CI/CD setup
Tool Configuration
Tools are configured with dependencies, installers, and platform support:
{
"name": "vscode",
"required": true,
"installer": "brew",
"platform": ["macos", "linux"],
"config": {
"extensions": ["ms-vscode.vscode-typescript-next"],
"settings": {"editor.formatOnSave": true}
}
}🚢 Docker Environments
Human Developer Container
# Start with VS Code Server
docker-compose up human-dev
# Access VS Code at http://localhost:8080AI Agent Container
# Start with Claude Flow orchestration
docker-compose up ai-agent
# Claude Flow API at http://localhost:3100Development with Docker
# Override for development
docker-compose -f docker-compose.yml -f docker-compose.dev.yml up
# Production deployment
docker-compose -f docker-compose.yml -f docker-compose.prod.yml up -d🔍 Validation & Health Checks
Environment Validation
# Comprehensive validation
wundr-env validate --verboseChecks:
- Tool installation and versions
- Platform compatibility
- Dependency resolution
- Configuration integrity
Quick Health Check
# Essential tools check
node --version && npm --version && git --versionAutomated Monitoring
- Health check endpoints in Docker containers
- Prometheus metrics collection
- Grafana dashboard visualization
🧪 Testing
Unit Tests
# Run unit tests
pnpm test
# Run with coverage
pnpm test:coverageIntegration Tests
# Test full environment setup
pnpm test:integration
# Test specific platform
PLATFORM=macos pnpm test:integrationEnd-to-End Tests
# Test complete workflow
pnpm test:e2e📚 API Reference
EnvironmentManager
Main class for environment management:
import { EnvironmentManager } from '@wundr/environment';
const manager = new EnvironmentManager();
// Initialize environment
await manager.initialize('human', {
email: '[email protected]',
fullName: 'User Name'
});
// Install tools
await manager.installEnvironment();
// Validate setup
const health = await manager.validateEnvironment();ProfileManager
Manage environment profiles:
import { ProfileManager } from '@wundr/environment';
const profiles = new ProfileManager();
// Get profile template
const template = await profiles.getProfileTemplate('ai-agent');
// Register custom profile
profiles.registerProfile(customProfile);ToolManager
Handle tool installation and validation:
import { ToolManager } from '@wundr/environment';
const tools = new ToolManager();
// Install tool
await tools.installTool(toolConfig);
// Validate tool
const result = await tools.validateTool(toolConfig);🤝 Contributing
We welcome contributions! Please see our Contributing Guide for details.
Development Setup
# Clone repository
git clone https://github.com/wundr/wundr.git
cd wundr/packages/@wundr/environment
# Install dependencies
pnpm install
# Start development
pnpm run dev
# Run tests
pnpm test
# Build package
pnpm run buildAdding New Profiles
- Create profile template in
templates/profiles/ - Add profile type to
src/types/index.ts - Update
ProfileManagerwith new profile - Add tests for the new profile
- Update documentation
Adding New Installers
- Extend
BaseInstallerclass - Implement
install()andvalidate()methods - Register installer in
ToolManager - Add platform-specific logic
- Add comprehensive tests
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🙏 Acknowledgments
- Homebrew for macOS package management
- Chocolatey for Windows package management
- NodeSource for Node.js distributions
- Anthropic for Claude AI integration
- All contributors and maintainers
Built with ❤️ by the Wundr team for the developer community.
