mirror of
https://github.com/ivuorinen/everforest-resources.git
synced 2026-01-26 11:13:59 +00:00
- Add LICENSE file (MIT) - Add CONTRIBUTING.md with generator-first workflow guidelines - Add Makefile with comprehensive development commands - Add .editorconfig for consistent code formatting - Add CHANGELOG.md for version tracking - Remove inconsistent non-variant files that bypassed generator architecture - Fix installation script to use variant-specific paths (prevent config overwriting)
4.4 KiB
4.4 KiB
Contributing to Everforest Resources
Thank you for your interest in contributing to Everforest Resources! This project follows a generator-first approach where all theme files are generated from canonical palette definitions.
Quick Start
git clone https://github.com/ivuorinen/everforest-resources.git
cd everforest-resources
npm install
npm run generate
Development Workflow
1. Edit Only Source Files
Critical Rule: Only edit these files:
palettes/everforest.jsonorpalettes/everforest.yaml- Canonical color definitionstemplate.txtfiles - Theme templates with color placeholders
Never edit generated files directly - they will be overwritten by the generator.
2. Template System
Templates use these placeholders:
{{bg}},{{bg1}},{{bg2}}- Background colors{{fg}}- Foreground color{{red}},{{orange}},{{yellow}},{{green}},{{aqua}},{{blue}},{{purple}}- Accent colors{{gray1}},{{gray2}},{{gray3}}- Gray variations
3. Generate and Test
npm run lint:fix # Auto-fix linting issues
npm run generate # Generate all theme files
npm run validate # Validate outputs
npm run ci # Full CI pipeline
4. Installation Testing
./install.sh --dry-run # Preview installation
./install.sh # Install themes
Adding New Tools
CLI Tools
- Create new directory:
cli/newtool/ - Add
template.txtwith color placeholders - Update
scripts/generate-themes.mjsto include the new tool - Update
install.shto install the new tool's themes - Test all 6 variants are generated correctly
Terminal Emulators
- Create new directory:
terminals/newterminal/ - Add
template.ext(appropriate file extension) - Update generator and installer
- Test with actual terminal application
Editors
- Create new directory:
editors/neweditor/ - Add appropriate template file
- Follow same pattern as existing editors
Code Quality
Linting and Formatting
npm run lint # Check code quality
npm run lint:fix # Auto-fix issues
npm run format # Format all files
All code must pass Biome linting and formatting checks.
Pre-commit Hooks
The project uses Husky for:
- Commit message validation: Must follow Conventional Commits
- Pre-commit checks: Linting and basic validation
Example commit messages: feat: add support for new terminal emulator fix: correct color mapping in dark variant docs: update installation instructions
CI/CD Pipeline
All PRs must pass:
- Lint: Biome code quality checks
- Build: Generator + validation
- Snapshots: Playwright visual testing
- Commitlint: Conventional commit format
- CLI Verify: Installation testing
Architecture Principles
- Generator-first: All outputs derive from
palettes/everforest.(json|yaml) - Template system: Use placeholders, not hardcoded values
- Variant completeness: All tools must support 6 variants (dark/light × hard/medium/soft)
- ANSI-only for CLI: CLI tools use ANSI codes, not hex values
- No manual edits: Generated files must never be hand-edited
Project Structure
palettes/ # Canonical color definitions
scripts/ # Generator and validation scripts
terminals/ # Terminal emulator themes
cli/ # CLI tool configurations
editors/ # Code editor themes
web/ # CSS themes and web demo
docs/ # Documentation
install.sh # Universal installer
verify/ # Container-based verification
Common Issues
Template Errors
- Ensure all placeholders use double braces:
{{color}} - Check template syntax matches target tool's format
- Verify all 6 variants generate without errors
Color Mapping
- CLI tools should use ANSI codes from palette
- GUI applications can use hex values
- Follow existing patterns for color assignments
Installation Issues
- Always install to variant-specific paths
- Never overwrite user configuration files
- Provide manual activation instructions
Getting Help
- Issues: GitHub Issues
- Discussions: Use GitHub Discussions for questions
- Documentation: Check
docs/directory andCLAUDE.md
License
By contributing, you agree that your contributions will be licensed under the MIT License.